
Keeping Parts of Your Codebase Private on GitHub - cleverjake
http://24ways.org/2013/keeping-parts-of-your-codebase-private-on-github/
======
jewel
An interesting way to share a private repo is with a sync tool such as dropbox
or btsync. In short, you create a bare repository locally, add that as a
remote, and then share the bare repo.

Detailed instructions about halfway through this blog post:
[http://stevenjewel.com/2013/09/cloudless/](http://stevenjewel.com/2013/09/cloudless/)

------
CmonDev
"I want the code to be open source so that people can poke through and learn
from it, but I want to keep any draft blog posts private until they are ready
to go live." \- the problem seems mixing code and content. I would recommend
decoupling on repo-/ NuGet-package level.

------
parennoob
A suggestion.

> You will need a paid github account

This should probably be the first line in the article, possibly even as a
broad "NOTE" above the entire post.

On the positive side though, this introduced me to showterm, which looks
amazing. Why don't more people use it for their 'casts?

------
Kronopath
Unfortunately, this only works if you want to keep parts of your repository
private temporarily, never merging them into master, and not if you want to
keep certain files or folders private permanently (when dealing with private
API keys and the like).

------
mzahir
You can have multiple git repositories within each other so you could just
`git init` in the directory you want private, add it to the parent repo's
.gitignore and point it to a different remote.

------
ameyp
Wouldn't it be easier and cleaner to just keep the private parts in a git
submodule?

------
theboss
Im very interested what advantages this has over gitignore?

~~~
pdwetz
If you use gitignore, the file(s) will only be local so they won't be
accessible by other team members (or yourself on a different machine) and may
not be backed up at all (depending on your strategy).

