
On Sat, May 19, 2018 at 03:09:35PM +1000, Brian May wrote:
Russell Coker <russell@coker.com.au> writes:
Well I can't create a repository, check files in, and then pull and push to it from other systems. I need to create an empty repository, push to it from somewhere, and then I can pull and push from anywhere.
I suspect what you need to do is adjust things slightly, so you can do what you want.
e.g. you can create a bare respository on somewhere. Then you can check out a working tree on the same system. This working tree can push/pull to the bare repository as much as you want. Furthermore you can checkout this bare respository on remote systems.
and don't forget 'git stash' - no fuss/no drama stashing away of any local changes & revert to HEAD. Then run git pull, and then merge your stashed crap. As a sysadmin who dabbles in programming and also writes documentation and other stuff with either markdown or latex, I love git. I used to use rcs, then cvs, then subversion. Now I use git pretty much exclusively. i've still got some fondness for the simplicity of rcs, but always hated cvs and to a lesser extent, svn - by design, a not-quite-as-awful cvs. IMO & IME for someone who's NOT a full-time developer so doesn't use it every day, git is easier to work with and much harder to fuck-up completely than cvs or even svn. By most accounts that's even more true for those who DO work with it every day. for most stuff I do, i'm using git as a glorified massively over-capable rcs clone with remote push/pull/fork capability (with "remote" mostly meaning "other hosts on my LAN"), but I also use several of its other features, especially when working with other people's code. There's probably less than 5% of what git's capable of that I know really well, but I've been using it long enough now that I'm confident that I can figure out anything else I need to do with it. and etckeeper with git is just awesomely useful. PS: I run a local gitlab ("github clone" is a semi-accurate brief description) in a docker container, and some of my stuff (dlocate and fakecloud) has two origins, so I can push to either or both of my local gitlab or to github. gitlab's overkill for most people (including me) but there are numerous alternatives. git itself includes git-daemon which is very basic, and there are also other options for fancy self-hosted git servers, like gitea and gogs. it's very convenient to have my own local git server with the same kind of features as github (and a few more) for personal stuff that I don't want uploaded to servers controlled by someone else.....and also so that I'm not dependant on some commercial provider and don't really have to GAF if they turn evil. Also convenient to have my own local repo to keep a clone of upstream projects. https://about.gitlab.com/ https://docs.gitea.io/en-US/ https://gogs.io/ BTW, both gitlab and gitea are packaged for debian. Running gitlab in docker is even easier, it was trivially easy to set up...i'd guess the same would be true for gitea. I would expect that for your consulting work, Russell, having git+ssh or https access to your personal git repos from client sites would be very useful. could use, e.g., a different branch for each client to track customisations of common code. craig -- craig sanders <cas@taz.net.au>