I am very much new to Git. Can anyone help me understand the follwoing.
I've found a very helpful git clone syntax for doing builds where you do not need the entire git history of revisions. Note that this seems to require Git version 1.9+:
git clone -b <remoteBranch> --single-branch --depth 1 ssh://[email protected]:serverport/PathToProject <FolderName>
Notes:
This clones and checks out "remoteBranch" without the other branches, at a depth of 1 (so only the most recent file snapshots) into the folder "FolderName"
.git
directory exists.See CharelsB’s comment for tips on how to get more detailed answers ;).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With