diff options
author | Rob Cornish | 2015-07-09 13:42:16 +1000 |
---|---|---|
committer | Rob Cornish | 2015-07-09 13:42:16 +1000 |
commit | 8d76b100007fca8a6cdebbd6cf5a14cf0d617e2d (patch) | |
tree | fb0c0f635ca123545f89a8c9ee6bd763fa4ff7d3 /brscan3.install | |
download | aur-8d76b100007fca8a6cdebbd6cf5a14cf0d617e2d.tar.gz |
Initial commit
Diffstat (limited to 'brscan3.install')
-rw-r--r-- | brscan3.install | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/brscan3.install b/brscan3.install new file mode 100644 index 000000000000..4b1f28bfdcb7 --- /dev/null +++ b/brscan3.install @@ -0,0 +1,44 @@ + +# new package version +devices_file="/usr/local/Brother/sane/brsanenetdevice3.cfg" + +pre_install() { + /bin/true +} + +# new package version +post_install() { + /usr/local/Brother/sane/setupSaneScan3 -i + +} + +# the new package version +# old package version +pre_upgrade() { + # If user has already configured their scanner then make a config backup + if [ -f $devices_file ]; then + cp $devices_file $devices_file.backup || return 1 + fi +} + +# new package version +# old package version +post_upgrade() { + # After upgrade revert user's scanner config and delete a config backup + if [ -f $devices_file.backup ]; then + cp $devices_file.backup $devices_file || return 1 + rm $devices_file.backup || return 1 + fi +} + +# old package version +pre_remove() { + /usr/local/Brother/sane/setupSaneScan3 -e + /bin/true +} + +# old package version +post_remove() { + /bin/true +} + |