diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2015-05-24 23:58:03 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2015-05-24 23:58:03 -0600 |
commit | 903884b327d46eadefaf3362744b31006b5d729a (patch) | |
tree | 0ec8ecbf477629179b96baed354bcdfcaf1944e3 /src/abslibre-tools/libredbdiff | |
parent | e398216226767990c0453b4c2b9ef49b75473f19 (diff) |
Enforce two spaces after a period.
Diffstat (limited to 'src/abslibre-tools/libredbdiff')
-rwxr-xr-x | src/abslibre-tools/libredbdiff | 61 |
1 files changed, 25 insertions, 36 deletions
diff --git a/src/abslibre-tools/libredbdiff b/src/abslibre-tools/libredbdiff index f87c579..1d1d191 100755 --- a/src/abslibre-tools/libredbdiff +++ b/src/abslibre-tools/libredbdiff @@ -60,10 +60,10 @@ downloadfile() { if wget -q "$url" -O "$outfile"; then return 255 else - die "Failed to download %q. Exiting." "$outfile" + die "Failed to download %q. Exiting." "$outfile" fi elif [[ $init ]]; then - warning "%q already exists. Skipping." "$outfile" + warning "%q already exists. Skipping." "$outfile" fi } @@ -79,9 +79,9 @@ createdir() { local dir=$1 if [[ ! -e $dir ]] ; then msg "Creating directory %q" "$dir" - mkdir -- "$1" || die "Failed to create directory %q. Exiting." "$dir" + mkdir -- "$1" || die "Failed to create directory %q. Exiting." "$dir" elif [[ $init ]]; then - warning "%q already exists. Skipping." "$dir" + warning "%q already exists. Skipping." "$dir" fi } @@ -101,7 +101,7 @@ filenotfound() { local file=$1 if [[ ! -r $1 ]]; then error "Could not read %q." "$file" - die "Nothing done. It may be necessary to run %q without \ + die "Nothing done. It may be necessary to run %q without \ arguments as root to initialize %s." "$cmd" "$name" fi } @@ -166,26 +166,22 @@ repo_test() { fi done if [[ $found != 1 ]] ; then - die "The specified Parabola repo \"%s\" cannot be compared. It's \ -not in the list of repos in the configuration variable \"repos\"." "$1" + die "The specified Parabola repo \"%s\" cannot be compared. It's not in the list of repos in the configuration variable \"repos\"." "$1" fi } expac_version_test() { if ! pkgname="$(pacman -Qoq expac 2> /dev/null)" ; then - die "The command expac could not be found installed. The package \ -pcr/expac-relative 4-2.parabola1 (or later) must be installed." + die "The command expac could not be found installed. The package pcr/expac-relative 4-2.parabola1 (or later) must be installed." elif [[ $pkgname == expac-git ]] ; then true elif [[ $pkgname == expac-relative ]] ; then expac_ver="$(expac %v expac-relative)" if [[ $(vercmp "${expac_ver}" 4-2.parabola1) == -1 ]] ; then - die "The version of expac-relative installed on the system is \ -lower than needed." + die "The version of expac-relative installed on the system is lower than needed." fi else - die "expac command must be provided by pcr/expac-relative version \ -4-2.parabola1 (or later). This package must be installed." + die "expac command must be provided by pcr/expac-relative version 4-2.parabola1 (or later). This package must be installed." fi } @@ -240,8 +236,8 @@ usage() { print "Usage: %q [-n|-h]" "$cmd" print 'Show packages that need to be updated from Arch repositories.' echo - prose "Compares packages in Parabola repositories. Packages from - all configured Parabola repositories are compared. A Parabola + prose "Compares packages in Parabola repositories. Packages from + all configured Parabola repositories are compared. A Parabola repository name can be specified as argument to compare only packages in that repository." echo @@ -290,8 +286,7 @@ main() { if (( $UPDATE )) ; then if [[ $EUID != 0 ]]; then - die "To initialize %s or update %s pacman \ -databases, %s must be run as root (without arguments). Nothing done." \ + die "To initialize %s or update %s pacman databases, %s must be run as root (without arguments). Nothing done." \ "$name" \ "$name" \ "$cmd" @@ -301,11 +296,9 @@ databases, %s must be run as root (without arguments). Nothing done." \ -e "${conffilearch}" && \ -e "${mirrorlist}" && \ -e "${mirrorlist}" ]]; then - warning "At least one %s configuration file is \ -missing." \ + warning "At least one %s configuration file is missing." \ "${name}" - msg "Downloading and preparing missing \ -configuration files." + msg "Downloading and preparing missing configuration files." init=1 fi @@ -316,22 +309,22 @@ configuration files." if ! [[ -d "$dbpath" && \ -d "$dbpatharch" ]]; then - warning "At least one %s pacman DB directory \ -is missing. Synchronizing %s DB files." "${name}" "${name}" + warning "At least one %s pacman DB directory is missing. Synchronizing %s DB files." \ + "${name}" "${name}" fi createdir "$dbpath" msg "Synchronizing %s pacman databases for Parabola" "$name" - pacman --config "${conffile}" -Sy || \ - die "Failed to synchronize pacman database for Parabola. Exiting." + pacman --config "${conffile}" -Sy || + die "Failed to synchronize pacman database for Parabola. Exiting." createdir "$dbpatharch" msg "Synchronizing %s pacman databases for Arch" "$name" - pacman --config "${conffilearch}" -b "${dbpatharch}" -Sy || \ - die "Failed to synchronize pacman database for Arch. Exiting." + pacman --config "${conffilearch}" -b "${dbpatharch}" -Sy || + die "Failed to synchronize pacman database for Arch. Exiting." - msg "%s pacman databases are updated. %s is ready. Run %q -n to \ -print results." "$name" "$name" "$cmd" + msg "%s pacman databases are updated. %s is ready. Run %q -n to print results." \ + "$name" "$name" "$cmd" return 0 else filenotfound "${dbpath}" @@ -346,9 +339,7 @@ print results." "$name" "$name" "$cmd" if ! [[ -d "$dbpath" && \ -d "$dbpatharch" ]]; then - die "At least one %s pacman DB directory \ -is missing. To update %s pacman databases, %s must be run as root. \ -Nothing done." \ + die "At least one %s pacman DB directory is missing. To update %s pacman databases, %s must be run as root. Nothing done." \ "$name" \ "$name" \ "$cmd" @@ -360,8 +351,7 @@ Nothing done." \ grep -v '^ ' | \ awk -F/ '{print $2}' \ > ${arch_packages_tmp} || \ - die "pacman command to get Arch \ -package data has failed. Exiting." + die "pacman command to get Arch package data has failed. Exiting." chmod 777 ${arch_packages_tmp} while read -a line; do @@ -370,8 +360,7 @@ package data has failed. Exiting." expac --config "${conffile}" -S '%r/%n %v %S' \ > ${parabola_packages_tmp} || \ - die "expac command to get Parabola \ -package data has failed. Exiting." + die "expac command to get Parabola package data has failed. Exiting." chmod 777 ${parabola_packages_tmp} if [[ ${repo_arg} ]] ; then |