On Fri, Dec 07, 2012 at 10:49:23AM -0800,
lance....@gmail.com wrote:
[...]
> > > Phase1 is to simply do a git-pull every x minutes. If I click the git
> > > shell, then type git pull, things work, so is there a way to append the
> > > shortcut to include that git-pull?
[...]
> > Create a batch script to perform your task and enable the wincred
> > credential helper so your session can record your github credentials.
> > git config --global credential.helper wincred
> > git remote set-url --push origin
https://YOUR...@github.com/.....
> >
> > Try it out (you can use git push --dry-run origin master) to get the
> > credentials logged.
> > With that batch script ready you can create a scheduled task that runs
> > your batch script at regular intervals.
> > You may need to fetch the git-credential-wincred file from
> >
https://github.com/msysgit/git/downloads as I don't think its in the
> > 1.8.0 release.
> >
> Thanks, I will create the batch script once I see it working (I think that
> is the easiest part). So I downloaded the cred-helper, I extracted it to
> the git\libexec\git-core folder as it looks like that is where it belongs.
>
> I ran;
> git config --global credential.helper wincred
> git remote set-url --push origin
https://github.com/user/repo.git (I got
> this URL from the github site, under HTTP which I think is correct)
>
> Both of the above gave no output, errors, etc. so I guess that's good. I
> then ran the dry run test;
>
> C:\inetpub\wwwother\
domain1.com>git push --dry-run origin master
> Username for '
https://github.com': user
> Password for '
https://us...@github.com':
> fatal:
>
https://github.com/myrepo/reponame.git/info/refs?service=git-receive-pack
> not found: did you run git update-server-info on the server?
>
> I did try the update-server-info but got the same result. (Note for this
> user, the branch is pull only, not sure if that matters or not).
git-receive-pack is stated to receive objects (that is, on the server
side it's started to serve a push), and in your original mail you say
you want to pull, and now you also state that branch is for pulling
only. So I think the error you're seeing is exactly about this: you
cannot push to that branch.
Hence it looks you took the Pat's suggestion too literally, and should
have tried to pull to get the credentials logged, not push.