Commit e0a1ee7a authored by Per Cederqvist's avatar Per Cederqvist
Browse files

Preserve the executable bit.

parent e9b8b206
#!/bin/bash
# $Id: update-copyright,v 1.3 1995/01/01 20:48:39 ceder Exp $
# $Id: update-copyright,v 1.4 1995/01/08 11:25:04 ceder Exp $
# Copyright (C) 1994, 1995 Lysator Academic Computer Association.
#
# This program is free software; you can redistribute it and/or modify
......@@ -42,7 +42,12 @@ do
< $file > /tmp/$$.file
cmp /tmp/$$.file $file >/dev/null
if [ $? = 1 ]; then
cat /tmp/$$.file > $file;
if [ -x $file ]; then
cat /tmp/$$.file > $file;
chmod +x $file
else
cat /tmp/$$.file > $file;
fi
echo $file updated
fi
done
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment