If I want to zip a directory up from my git repository will it contain git messages?
If your zip file contains the .git
folder, yes it will. If the .git
folder is not present, then the commit messages will not be contained. However, unless you also remove .gitignore
, .gitattributes
and .gitmodules
files, someone will be able to tell that it was once tracked through git.
How would I export a directory without any version control?
Just use git archive
1, as also linked in the duplicate question 2. If you just want a subdirectory, you may zip that directly.
If possible if it's a feature from Github.
Here is how you can create releases on GitHub: https://help.github.com/en/articles/creating-releases After doing this, you can automatically download the repository as a Zip or Tar file. Exactly what you want!
I have found and linked to this post but it is not clear if it's the same thing as I'm asking and it's from 2008:
Do a "git export" (like "svn export")?
Yes, your question is mostly a duplicate.
Can I simply copy the directories locally? It's the root directory that has a hidden version control folder correct?
Yes, this is correct. All the version data is stored inside the root's .git
folder.
I found git-archive that makes a zip: https://alvinalexander.com/git/git-export-project-archive-cvs-svn-export
Just use the builtin git archive
tool for that.