[GTALUG] Slightly OT: git question

Myles Braithwaite me at mylesbraithwaite.com
Tue Aug 11 16:36:30 UTC 2015


Giles Orr wrote:
> I'm writing a Python script that checks git repositories in the user's
> home folder (other folders is an option that should be added soon) and
> then tells you their status, both local and remote.  I want to release
> it publicly using github, but I'd like to maintain a private repo, and
> only push certain releases to github.  I admit this is mostly because
> I keep extensive notes in the source code and am perhaps a bit
> embarrassed what those notes say both about my memory and my limited
> coding skills.  I should probably just get over it - particularly
> since the code itself probably says more than the notes.  But - git is
> flexible enough that I imagine that this is an option: has anybody
> done this?

If you don't want to share the commit messages you can change the easily
with `git commit --amend` (see this
<https://help.github.com/articles/changing-a-commit-message/>).

If you are afraid of things you have committed you can use `git rebase
-i HEAD~10` which will allow you to squash the last 10 commits and allow
you to rewrite the commit message.

I would clone a new repo to test how it's going to work. You don't want
an detached head :-).

Have you seen this: <https://github.com/mixu/gr> it's basically what you
are doing written in Node.js.


More information about the talk mailing list