Skip to content

Instantly share code, notes, and snippets.

@AdityaDeshmane
Last active December 31, 2015 07:27
Show Gist options
  • Save AdityaDeshmane/d6484a32ab29663e9990 to your computer and use it in GitHub Desktop.
Save AdityaDeshmane/d6484a32ab29663e9990 to your computer and use it in GitHub Desktop.
Mac file split and join commands
Split:
split -b YOUR_EXPECTED_SIZES YOUR_FILE_NAME PATTERN_NAME_AS_OUTPUT
Join:
cat SPITED_FILES_AS_LIST > NEW_FILE
Example:
Split:
split -b 1024m "XCode_7.2.dmg" "XCode_7.2.dmg."
files will be with extension
XCode_7.2.dmg.aa
XCode_7.2.dmg.ab
...
XCode_7.2.dmg.ae (the last file will be less than 1024mb)
Join:
cat XCode_7.2.dmg.* > XCode_7.2.dmg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment