开发者

Master failed to write error while pushing commit

I have a git repository on a company network drive and had no problem pulling from it. However, i wasn't able to push any commits into it, though I had a few good luck but recently I couldn't get anything in it. The error was:

C:\Program Files\Git\bin\git.exe push "origin" master:master error: Couldn't set refs/heads/master To //software/pdd.git/ ! [remote rejected] master -> master (failed to write) error: failed to push some refs to '//software开发者_开发技巧/pdd.git/' Done

I suspect that it got to with the master file. On Windows, it shows that I might have been put into a network group that does not allow me to do modify but was able to read, write and execute.

My question is: If i was able to push a few times before, this file permission thing shouldm't be a hassle to me. If it, indeed, that I don't have enough privillage to modify, is there a workaround?

PS: The company is reluctant to change my network group to another, which would enable me to modify files.


Check the question "Pushing to a Git repository on an NFS share fails":

The NAS is doing weird things to permissions, setting the sticky bit on all directories. This explains the behavior. An additional chmod solved the problem.

That means this is a permission issue on the target (remote) side, as illustrated in "Git issues after upgrading to osx Lion":

there was an odd permission for everyone as ‘custom’. I updated this to be ‘Read & Write’ and the commit was finally successful.

As a "workaound", See this Error section:

I just deleted my bare repository and created a brand new one and pushed my changes over there. And everything works again.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜