• JackbyDev
    link
    fedilink
    English
    arrow-up
    2
    ·
    2 months ago

    git config --global alias.pusho 'push --set-upstream origin HEAD'

    You’re welcome.

      • JackbyDev
        link
        fedilink
        English
        arrow-up
        1
        ·
        edit-2
        2 months ago

        When you’re pushing a new branch you’ve never pushed before you need the -u command. That’s what this alias is for.

        As long as the config’s push.default isn’t matching, git push without arguments will only push the current branch.