Hi, folks! I’m trying to send commits from origin to another branch:

git push -uf origin foo2

Then I gets it:

branch ‘foo’ set up to track ‘origin/foo2’.

But when I’m trying to do this:

git push -uf origin origin/foo2

It writes me:

Everything up-to-date

And commits don’t be sent.

Now I’m using ‘foo’ branch.

And the list of changes:

changed: scripts/file1.gd

changed: scripts/file2.gd

changed: scripts/file3.gd

Is still not empty. After I sends commits - nothing changes.

I don’t know what do I do wrong. Can you help me? 🤷🏻‍♂️

  • tyler@programming.dev
    link
    fedilink
    arrow-up
    2
    ·
    7 days ago

    If foo is set to track origin/foo you don’t need to do anything except git push. But it sounds like you haven’t actually staged and committed your changes yet so you need to do that first. git add the files you want to commit and then git commit them with a message.