code cleanup

This commit is contained in:
SinTan1729 2022-07-31 00:27:10 -05:00 committed by GitHub
parent 5fe58e29f2
commit 7d2a42b8ad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

6
makebk
View File

@ -1,13 +1,13 @@
#!/bin/sh
# This simply makes a backup of a file as filename.bak
# This simply makes backup of file(s) as filename.bak
if [ $# -ge 1 ]; then
for f in $@
do
[ -f "$f" ] &&cp "$f"{,.bak}
[ -f "$f" ] && cp "$f"{,.bak}
done
else
echo "No filenames passed."
exit 1
fi
fi