Skip to content

Instantly share code, notes, and snippets.

@Dillie-O
Last active September 19, 2019 21:10
Show Gist options
  • Save Dillie-O/72f6035a7d1a6a021af3de64dd7776dc to your computer and use it in GitHub Desktop.
Save Dillie-O/72f6035a7d1a6a021af3de64dd7776dc to your computer and use it in GitHub Desktop.
[Clone Git Repo Without History] Clone Git repo without history #powershell #git
$location = "[path_to_new_folder]"; git archive master --format zip -o "$location.zip"; expand-archive "$location.zip" -DestinationPath $location; ri "$location.zip"
# Expand-Archive will auto-create destination folder.
# Can use path such as $HOME/Projects/my_project to shortcut.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment