Skip to content

Instantly share code, notes, and snippets.

@courtney-rosenthal
Created March 29, 2016 15:21
Show Gist options
  • Save courtney-rosenthal/611c6db2ede1c11f9732 to your computer and use it in GitHub Desktop.
Save courtney-rosenthal/611c6db2ede1c11f9732 to your computer and use it in GitHub Desktop.
Apply the Subversion svn:ignore property to files.
#!/bin/sh
#
# svnignore - Apply the Subversion svn:ignore property to files.
#
# Chip Rosenthal
# chip@unicom.com
USAGE="usage: $0 FILE ..."
case "$1" in
''|-*)
echo "$USAGE" >&2
exit 1
;;
esac
for p in $@ ; do
f=`basename $p`
d=`dirname $p`
i=`svn propget svn:ignore "$d"`
svn propset svn:ignore "$i
$f" $d
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment