Content
stackoverflow Questions git rebase: "error: cannot stat ‘file’: Permission denied" 91 13 I’m using git, and made a small commit followed by a large one. I decided to use git rebase to squash the two commits together before pushing them. (I’ve never done this before.) So l did: git rebase – i HEAD-2 This gave me my editor, where I chose to pick the earlier commit and squash the later one. When I saved, git said: error: cannot stat ‘filename’: Permission denied Could not apply sha1 for later commit… initial line of text for that commit Now: Neither commit appears when I do git log. git status tells me I’m "Not currently on any branch." One file is listed as modified and in the index, and two files are listed as untracked. My first commit had just one file (I think), and my second commit had a good dozen. What happened!? How do I fix it? gIt I git-rebase share edit close flag asked May 11 ’11 at 21:33 Kyraless: 116k 26 137 183 Are you, by and chance, using git on windows? – Charles Bailey May 11 ’11 at 21:35 Yes. I run the commands in a DOS window. – Kyralessa May 11 ’11 at 21:36 49 Just close VISUAL STUDIO. It might work share edit flag answered Sep 25 ’13 at 19:55 GEl Mandan 03 616 This worked for mel – Fillip Peyton Aug 15 ’14 at 18:45 this is the correct answer.. Thank You! – toha Dec 17 ’14 at 7:51 I had visual studio locking those files, too. Unlocker showed me. – Varga Tamas Jan 14 ’15 at 8:13 Thank you! Worked for me – juliet Feb 11 ’15 at 22:16