Currently, I work on a team that does trunk based development.
We moved the project from SVN
to GIT
recently, which requires me to do a push after every commit (Ctrl+K followed by Ctrl+Shift+K).
Is there a way to configure IntelliJ to push changes to origin/master after every commit?
Do one of the following: To push changes from the current branch press Ctrl+Shift+K or choose Git | Push from the main menu. To push changes from any local branch that has a remote, select this branch in the Branches popup and choose Push from the list of actions.
Alternatively, you can use ⌘K (macOS), Ctrl+K (Windows/Linux) to commit your changes, or ⌥⌘K (macOS), Ctrl+Shift+K (Windows/Linux) to commit and push your changes. If you commit and push your changes you will be able to select your remote repository in the next step.
Select the files you want to add to Git or the entire changelist and press Ctrl+Alt+A or choose Add to VCS from the context menu. You can also add files to your local Git repository from the Project tool window: select the files you want to add, and press Ctrl+Alt+A or choose Git | Add from the context menu.
There is no option to always perform commit and push automatically. However, there is a shortcut to perform these two operations together manually. If you hover over the "Commit" button in the Commit Changes dialog, you'll see the "Commit and Push" option, which will push the changes after you commit them.
if i work in Windows 10 with PhpStorm 2018.1 EAP, then i using this script for AutoHotkey Version 1.1.28. for commit and push with just one shortcut (Ctrl+K).
#IfWinActive,ahk_class SunAwtFrame
~^k:: ; thats Ctrl+K
WinWaitActive,Commit Changes ahk_class SunAwtDialog,,3
Sleep,300
send,{CtrlDown}{Altdown}k{Ctrlup}{Altup} ; Ctrl+Alt+K that commits and pushes
WinWaitActive,Push Commits ahk_class SunAwtDialog,,3
Sleep,200
send,{Altdown}p{Altup} ; push
Msgbox,macro for git push in IntelliJ finished `n developed:SL5net, 23.03.2018 17:11`n (%A_LineFile%~%A_LineNumber%)
return
installer for autohotkey : https://autohotkey.com/download/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With