Suppose I have git repository like this:
git-repo/
directory_1/
directory_2/
directory_3/
This has a long history, and the history contains some code that I don't want anyone to have access to. I also don't want to release directory_1
.
I want to release directory_2
and directory_3
, but with no history information. Going forward, I will be continuing development in the original repository, and would like to also update the release fork with these changes.
The original repository is hosted as a private repository on github right now.
How should I do this?
Given your clarification, it sounds like this setup could work for you:
The public repo won't inherently share any history with the private repo, but it sounds like that might not matter much for your purposes.
I would first go to the download page for your private repo, something like
github.com/jquery/jquery/downloads
Here you can simply get the files from the current repo with no history. After that you can create a new repo, and git commit
in only the files/folders that you are wanting on the new repo.