Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save prithv1/83655754abc13ed80e06bfcc662177c9 to your computer and use it in GitHub Desktop.

Select an option

Save prithv1/83655754abc13ed80e06bfcc662177c9 to your computer and use it in GitHub Desktop.

Revisions

  1. @jfarsen jfarsen created this gist Aug 9, 2017.
    7 changes: 7 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@
    @url https://major.io/2007/07/05/bintar-argument-list-too-long/

    If you find yourself stuck with over 30,000 files in a directory (text files in this example), packing them into a tar file can be tricky. You can get around it with this:

    find . -name '*.txt' -print >/tmp/test.manifest
    tar -cvzf textfiles.tar.gz --files-from /tmp/test.manifest
    find . -name '*.txt' | xargs rm -v