This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
env=~/.ssh/agent.env | |
agent_load_env () { test -f "$env" && . "$env" >| /dev/null ; } | |
agent_start () { | |
echo "Starting new SSH agent" | |
(umask 077; ssh-agent >| "$env") | |
. "$env" >| /dev/null ; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protected function _websiteFilter($collection, $column) | |
{ | |
if (!$value = $column->getFilter()->getValue()) { | |
return $this; | |
} | |
$stores = Mage::app()->getWebsite($value)->getStores(); | |
foreach ($stores as $store) { | |
$collection->addStoreFilter($store); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git config --global alias.cm 'commit -m' | |
git config --global alias.st status |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# check if upstream is configured | |
git remote -v | |
git fetch # pull ahead commits from remote | |
git fetch upstream | |
git merge upstream/branch_name | |
git push | |
git log -n 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[mysql] | |
host= | |
port= | |
user= | |
password= | |
database= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. git rebase --interactive HEAD~10 | |
2. pick commit and replace `pick` for "child" commits to `s` (it means squash) | |
3. save & force push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd submodule | |
git reset --hard HEAD | |
git clean -fd . | |
cd .. | |
git submodule update --init --recursive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# GIT bash integration | |
if [[ -e /usr/lib/git-core/git-sh-prompt ]]; then | |
source /usr/lib/git-core/git-sh-prompt | |
export GIT_PS1_SHOWCOLORHINTS=true | |
export GIT_PS1_SHOWDIRTYSTATE=true | |
export GIT_PS1_SHOWUNTRACKEDFILES=true | |
export GIT_PS1_SHOWUPSTREAM="auto" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
clear | |
prefix="" | |
ls -d */ | while read -r folder; | |
do | |
cd "$folder" | |
echo "Before:" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git config --global push.default current |