git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Can't seem to commit

From
Chris Packham <judge.packham@gmail.com>
Date
Dec 6, 2010, 08:54 UTC
Message-ID
<4CFCA4CD.4050100@gmail.com>
In-Reply-To
<4CFCA445.2020205@gmail.com>
Sorry for the dupe, I forgot to CC the list.
On 05/12/10 05:33, weloki wrote:
Show 11 quoted lines
>
> There is probably an easy solution to this but I'm seeing something really
> weird...
> I can't seem to commit anything to my new branch. When I try to commit it
> just says "no changes added to commit (use "git add" and/or "git commit
> -a")"
> When I try to do git add it doesn't seem to do anything.
> When I try to push it says "Everything up-to-date", but when I look at the
> branch on github my files aren't there.
> Strangely I was able to do everything fine with a different branch I created
> afterwards.

One thing to check is where you're pushing to ("git remote show origin" should tell you). You may also want to check the value of "git config branch.master.merge", "git config remote.origin.url" and "git config push.default".

For me these are refs/heads/master <my github project> tracking

Also on a very fresh repository you need to use "git push origin master:refs/heads/master" to create the master branch on the remote end.

Previous: Andreas Schwab
Message 3 of 3 in “Can't seem to commit”
  1. welokiDec 4, 2010
  2. Andreas SchwabDec 4, 2010
  3. Chris PackhamDec 6, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.