diff options
author | Dustin Schnee <schnee72{at}gmail{dot}com> | 2011-09-13 07:57:58 -0300 |
---|---|---|
committer | Niels Horn <niels.horn@slackbuilds.org> | 2011-09-13 07:57:58 -0300 |
commit | dd5795e152591c07b1e809109434042916eca07f (patch) | |
tree | 06bc6a4cecef2eea20d62c0900cc180df6dc71e8 /development/avrdude/doinst.sh | |
parent | 41b839dabf401b2b40bd602588fa4ed0d3dbb437 (diff) | |
download | slackbuilds-dd5795e152591c07b1e809109434042916eca07f.tar.gz |
development/avrdude: Updated for version 5.11.
Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
Diffstat (limited to 'development/avrdude/doinst.sh')
-rw-r--r-- | development/avrdude/doinst.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/development/avrdude/doinst.sh b/development/avrdude/doinst.sh new file mode 100644 index 0000000000..5a912d545b --- /dev/null +++ b/development/avrdude/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/avrdude.conf.new |