Skip to content

Instantly share code, notes, and snippets.

View stunko's full-sized avatar

Eugeny Kurkovich stunko

View GitHub Profile
@stunko
stunko / .kitchen.yml
Last active February 5, 2016 11:51
chef kitchen-ec2
---
driver:
name: ec2
aws_ssh_key_id: Key_pair_name
availability_zone: us-east-1d
shared_credentials_profile: default
transport:
ssh_key: <%= ENV['AWS_VAGRANT_SSH_KEY'] %>
associate_public_ip: true
git show-branch | grep "*" | grep -v "$(git rev-parse --abbrev-ref HEAD)" | head -n1 | sed "s/.*\[\(.*\)\].*/\1/" | sed "s/[\^~].*//"
import json
import uuid
import logging
from common.utils import mixutil
import locust
import gevent
import gevent.lock
import gevent.event
@stunko
stunko / gist:3f565b5d221b003b3f7e
Last active August 29, 2015 14:14
Vim help. Command list
Move cursor down one line j Basic
Move cursor up one line k Basic
Move cursor left one character h Basic
Move cursor right one character l Basic
Return to Normal mode <ESC>
(escape) Basic
Exit the editor, discarding any changes :q!<ENTER> Basic
Exit the editor, but abort if there are unsaved changes :q<ENTER> Basic
Delete the character under the cursor x Basic
Insert text before the cursor i Basic
@stunko
stunko / gist:55a265b543bc197b859d
Last active August 29, 2015 14:04
Git revert changes between some commits using diff patch
git diff <new commit> <old commit> | git apply
git commit -am 'Text commit' | git push
@stunko
stunko / gist:7263311
Created November 1, 2013 10:03
git searching HEAD
a. git reflog
git reset SHA1
git reset HEAD@{5}
git reset HEAD~5
git reset HEAD@{yesterday}
git reset HEAD@{2.months.ago}
b. git log -g
@stunko
stunko / .gitconfig
Last active December 27, 2015 03:49
.gitconfig aliases samples
[alias]
st = status
br = branch
chp = cherry-pick
cht = checkout
#Push tag's to remote repo. Example pushtag origin
pushtag = !sh -c 'git push $1 --tags' -
#Fetch tag's from remote repo. Example fetchtag origin