autotool scripts/updatesync
- move scripts/updatesync -> scripts/updatesync.in - add -V --version options to scripts/updatesync.in - add autotool commands to generate scripts/updatesync Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
This commit is contained in:
parent
48946b624b
commit
e9e19b7cc6
3 changed files with 22 additions and 7 deletions
|
@ -224,6 +224,7 @@ scripts/makeworld
|
||||||
scripts/pacman-optimize
|
scripts/pacman-optimize
|
||||||
scripts/repo-add
|
scripts/repo-add
|
||||||
scripts/repo-remove
|
scripts/repo-remove
|
||||||
|
scripts/updatesync
|
||||||
doc/Makefile
|
doc/Makefile
|
||||||
etc/Makefile
|
etc/Makefile
|
||||||
etc/makepkg.conf
|
etc/makepkg.conf
|
||||||
|
|
|
@ -21,6 +21,6 @@ EXTRA_DIST = abs.in \
|
||||||
rankmirrors \
|
rankmirrors \
|
||||||
repo-add.in \
|
repo-add.in \
|
||||||
repo-remove.in \
|
repo-remove.in \
|
||||||
updatesync
|
updatesync.in
|
||||||
|
|
||||||
abs gensync makepkg makeworld pacman-optimize rankmirrors repo-add repo-remove re-pacman updatesync:
|
abs gensync makepkg makeworld pacman-optimize rankmirrors repo-add repo-remove re-pacman updatesync:
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
# USA.
|
# USA.
|
||||||
#
|
#
|
||||||
|
|
||||||
myver='3.0.0'
|
myver='@PACKAGE_VERSION@'
|
||||||
|
|
||||||
# functions
|
# functions
|
||||||
|
|
||||||
|
@ -49,6 +49,15 @@ usage() {
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
version() {
|
||||||
|
printf "updatesync (pacman) %s\n" "$myver"
|
||||||
|
printf "Copyright (C) 2004 Jason Chu <jason@archlinux.org>.\n"
|
||||||
|
echo
|
||||||
|
printf "This is free software; see the source for copying conditions.\n"
|
||||||
|
printf "There is NO WARRANTY, to the extent permitted by law.\n"
|
||||||
|
echo
|
||||||
|
}
|
||||||
|
|
||||||
error () {
|
error () {
|
||||||
echo "==> ERROR: $*" >&2
|
echo "==> ERROR: $*" >&2
|
||||||
}
|
}
|
||||||
|
@ -71,16 +80,21 @@ check_force () {
|
||||||
|
|
||||||
# PROGRAM START
|
# PROGRAM START
|
||||||
|
|
||||||
if [ $# -lt 3 ]; then
|
|
||||||
usage
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$1" = "-h" -o "$1" = "--help" ]; then
|
if [ "$1" = "-h" -o "$1" = "--help" ]; then
|
||||||
usage
|
usage
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$1" = "-V" -o "$1" = "--version" ]; then
|
||||||
|
version
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $# -lt 3 ]; then
|
||||||
|
usage
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# source system and user makepkg.conf
|
# source system and user makepkg.conf
|
||||||
if [ -r /etc/makepkg.conf ]; then
|
if [ -r /etc/makepkg.conf ]; then
|
||||||
source /etc/makepkg.conf
|
source /etc/makepkg.conf
|
Loading…
Add table
Reference in a new issue