Skip to content

Instantly share code, notes, and snippets.

@lira
Forked from davidhemphill/gist:5188894
Created September 19, 2023 18:29
Show Gist options
  • Save lira/6e91b2b74f48515acfaccfa9c77cf69b to your computer and use it in GitHub Desktop.
Save lira/6e91b2b74f48515acfaccfa9c77cf69b to your computer and use it in GitHub Desktop.
How to do a Git clone without the .git directory
// Clone the repo
git clone --depth=1 git://someserver/somerepo dirformynewrepo
// Remove the .git directory
rm -rf !$/.git
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment