Skip to content

Instantly share code, notes, and snippets.

@monolithed
Created June 9, 2013 16:12
Show Gist options
  • Save monolithed/5744106 to your computer and use it in GitHub Desktop.
Save monolithed/5744106 to your computer and use it in GitHub Desktop.
# remove :: from file name
# bad version
for file in ::*;
do
mv $file `echo $file | sed -e 's/^:://'`;
done;
# bad version
for file in $(ls);
do
mv $file `echo $file | cut -b 3-;
done;
# good version
for file in $(ls);
do
mv $file ${file#::};
done;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment