I'm getting my mind round the mechanics of using git better now but before I go too far I have a couple of more 'philosophical' questions about it - not in the Plato/Sophocles sense, more in the how to use it sense! :-)
It seems to make sense to me to use git 'directly' to manage places like ~/bin where one has a mixed bag of shell scripts and python. I.e. make ~/bin into a git repository. I don't see any significant downside to this, ~/bin is only for one's own use so you modify/create a script, test it and then 'git add' it to preserve the history.
However I'm not quite so sure how to handle bigger projects and/or ones where there are multiple users (or at least multiple installations on my system).
Taking dokuwiki (my current example) I can set up a local git repository which is derived from the dokuwiki repository latest stable release and then I can add patches of my own etc. and when the stable release moves on I can merge the patches into the new release. So far so good. However I'm not clear how, having got the 'stable release plus patches' 'git add'ed into the repository how do I then copy out to the various installations? I can't just copy what's in the repository as it appears because that *may* have further un-added changes. I don't really want to run every installation as a git repository. Is there a command to extract all the files from a given branch in git (which doesn't create a new repository)?
http://stackoverflow.com/questions/2866358/git-checkout-only-files-without-r...
On 11 Aug 2011, at 09:19, Chris G wrote:
Is there a command to extract all the files from a given branch in git (which doesn't create a new repository)?
-- Chris Green
main@lists.alug.org.uk http://www.alug.org.uk/ http://lists.alug.org.uk/mailman/listinfo/main Unsubscribe? See message headers or the web site above!
On Thu, Aug 11, 2011 at 09:36:15AM +0100, Martijn Koster wrote:
On 11 Aug 2011, at 09:19, Chris G wrote:
Is there a command to extract all the files from a given branch in git (which doesn't create a new repository)?
http://stackoverflow.com/questions/2866358/git-checkout-only-files-without-r...
Ah, so it's not something obvious I had missed then! :-)
I.e. it's not something git does 'out of the box' really, though as the discussion at the above link shows it's fairly easy to do by a couple of different means.
I think I'll just implement a little script that 'pushes' the latest branch out to my several dokuwiki installations. It can be kept as a local patch in my dokuwiki repository. (By the way one can implement Dokuwiki 'farms' but it's not too easy and as disk space is cheap it's simpler to simply have multiple installations)
Thanks for the various help so far.