Skip to content

Instantly share code, notes, and snippets.

@frankus
Created August 13, 2015 00:14
Show Gist options
  • Save frankus/f13830ea658bed55ca41 to your computer and use it in GitHub Desktop.
Save frankus/f13830ea658bed55ca41 to your computer and use it in GitHub Desktop.
Updates Xcode's default file-header comment to correct filename
find . -iname '*.[mh]' -print0 | while IFS= read -r -d '' file; do basename=`basename "$file"`; sed -i .bak "2s|// .*\$|// $basename|" "$file"; done
@frankus
Copy link
Author

frankus commented Oct 24, 2022

To delete backup files:

find . -name "*.bak" -delete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment