How do I set up an alias for "git push heroku master"?
-
such that i can just write git push, as opposed to git push heroku master
-
Answer:
I don't know if there's something already built into Git, but you can do something like this (via Terminal): $ alias letspush="git push heroku master" Then use the command "letspush" to push changes to heroku: $ letspush Note: you can change "letspush" with whatever you want. This solution will stop working as soon as you reboot. If you happen to like it, you can make it permanent by adding the alias command at the bottom of your ~/.bash_profile. You can do this via Terminal: $ echo "alias letspush=\"git push heroku master\"" >> ~/.bash_profile Again, change letspush as you like.
Giovanni Piller Cottrer at Quora Visit the source
Other answers
You can configure Git to record an alias. Add this to your gitconfig file : [alias] deploy = push heroku master Now you just need to write git deploy. Of course if you don't like 'deploy' you can use any other alias that you want. If you're new to aliases in git, read here for some common/useful aliases :
Nikhil Garg
Just run 'git push -u heroku master' and then from then on you can just run 'git push'
Chris Bolton
Related Q & A:
- How can I set up my computer to alert me when I get an incoming email?Best solution by Yahoo! Answers
- How do I set my e-mail to alert me when I get a new message?Best solution by Yahoo! Answers
- How do I set up an I.M. on Yahoo?Best solution by answers.yahoo.com
- How do I set up my set top box?Best solution by Server Fault
- How do you set up an alias on your mail?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.