diff options
| author | Danilo M. <danix@danix.xyz> | 2026-06-30 15:16:27 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-06-30 15:16:27 +0200 |
| commit | 00c1e61505d2e3d575421780cb47a8344eddf077 (patch) | |
| tree | 95fa1ca837419d273a2d9b43f583223383671410 /firefly-cli/doinst.sh | |
| parent | c9b9cf84a6d0cd11bcfbce0fca1dad02a70c9e47 (diff) | |
| download | my-slackbuilds-main.tar.gz my-slackbuilds-main.zip | |
firefly-cli: update to 0.2.1main
Bump to 0.2.1 and ship the bash completion script as
/etc/bash_completion.d/firefly.new, merged on install via a
standard SBo doinst.sh config() handler.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'firefly-cli/doinst.sh')
| -rw-r--r-- | firefly-cli/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/firefly-cli/doinst.sh b/firefly-cli/doinst.sh new file mode 100644 index 0000000..9514c89 --- /dev/null +++ b/firefly-cli/doinst.sh @@ -0,0 +1,14 @@ +config() { + NEW="$1" + OLD="$(dirname $NEW)/$(basename $NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r $OLD ]; then + mv $NEW $OLD + elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then + # toss the redundant copy + rm $NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +config etc/bash_completion.d/firefly.new |
