mirror of
https://github.com/octoleo/telegram-bot-bash.git
synced 2024-12-28 12:50:44 +00:00
dev: version.sh: ask to update ALL files
This commit is contained in:
parent
c4e2981116
commit
b1af0f07e7
@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
#### $$VERSION$$ v1.45-dev-75-gfdb2b3a
|
||||
#### $$VERSION$$ v1.45-dev-78-gc4e2981
|
||||
# shellcheck disable=SC2016
|
||||
#
|
||||
# Easy Versioning in git:
|
||||
@ -44,8 +44,14 @@ VERSION="$(git describe --tags --long)"
|
||||
printf "Update to version %s ...\n" "${VERSION}"
|
||||
|
||||
# only regular files, ignore .dot files/dirs, e.g. .git .gitinore in BASEDIR
|
||||
FILES="$(find ./* -type f)"
|
||||
[ "$1" != "" ] && FILES="$*"
|
||||
if [ -n "$1" ]; then
|
||||
FILES="$*"
|
||||
else
|
||||
printf "Update version string in all files? (y/N)\b\b"
|
||||
read -r answer
|
||||
[[ "${answer}" != "y" && "${answer}" != "Y" ]] && exit
|
||||
FILES="$(find ./* -type f)"
|
||||
fi
|
||||
|
||||
# autogenerate REMADME.html REMADE.txt
|
||||
if [[ "${FILES}" == *"README.md"* ]]; then
|
||||
|
Loading…
Reference in New Issue
Block a user