{"id":323,"date":"2021-05-19T17:23:46","date_gmt":"2021-05-19T17:23:46","guid":{"rendered":"http:\/\/www.evermoretechnologies.com\/blog\/?p=323"},"modified":"2021-05-19T17:25:28","modified_gmt":"2021-05-19T17:25:28","slug":"push-git-to-a-different-remote-branch-name","status":"publish","type":"post","link":"https:\/\/www.evermoretechnologies.com\/blog\/2021\/05\/push-git-to-a-different-remote-branch-name\/","title":{"rendered":"Push git to a different remote branch name"},"content":{"rendered":"<p>Sometimes your local branch name isn&#8217;t the same as the remote branch you want to push to.<\/p>\n<p>This recently came up for me because I needed to push to a specific branch to trigger a deployment.\u00a0 Instead of the standard git push origin branch-name, it&#8217;s easy enough to specify the remote branch you want using this syntax:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\">git push origin local-branch:remote-branch\r\n\r\n#My use case branch names where I had a feature I needed to review on a develop instance.\r\ngit push origin filter-feature:develop<\/pre>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sometimes your local branch name isn&#8217;t the same as the remote branch you want to push to. This recently came up for me because I needed to push to a&#8230; <a href=\"https:\/\/www.evermoretechnologies.com\/blog\/2021\/05\/push-git-to-a-different-remote-branch-name\/\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[40,38],"tags":[],"_links":{"self":[{"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/323"}],"collection":[{"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/comments?post=323"}],"version-history":[{"count":1,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/323\/revisions"}],"predecessor-version":[{"id":324,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/323\/revisions\/324"}],"wp:attachment":[{"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/media?parent=323"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/categories?post=323"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.evermoretechnologies.com\/blog\/wp-json\/wp\/v2\/tags?post=323"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}