Skip to content

Instantly share code, notes, and snippets.

@ezenkin
ezenkin / git_branch_date.sh
Created February 1, 2022 07:02
print branches update date
for k in `git branch | sed s/^..//`; do echo -e `git log -1 --pretty=format:"%Cgreen%ci %Cblue%cr%Creset" $k --`\\t"$k";done | sort
@ezenkin
ezenkin / .gitignore
Created July 2, 2021 12:44
Ignore files without extension
# Ignore all
*
# Unignore all with extensions
!*.*
# Unignore all dirs
!*/
@ezenkin
ezenkin / .vimrc
Last active October 29, 2023 08:24
my .vimrc
set tabstop=4 shiftwidth=4 expandtab smarttab
set smartindent "autoindent
set number
set cursorline
"highlight cursorline cterm=none ctermbg=darkgray
"highlight cursorlinenr cterm=none
colorscheme habamax
syntax on
@ezenkin
ezenkin / suffix_for_go_mod
Created October 26, 2020 13:32
Get suffix to add to a version in go.mod file
TZ=UTC git --no-pager show --quiet --abbrev=12 --date='format-local:%Y%m%d%H%M%S' --format="%cd-%h"
@ezenkin
ezenkin / git_reset_branch_to_origin.sh
Created August 7, 2020 06:43
git reset master to origin
git checkout -B master origin/master

This text aligned to the left

This text aligned to the center
This text aligned to the right
@ezenkin
ezenkin / github-lines-of-code.sh
Created June 19, 2020 11:08
show number of lines of code in a project
#!/bin/bash
git ls-files | xargs wc -l
@ezenkin
ezenkin / disable_shadowing_ctrl_alt_left_right_in_ubuntu.sh
Last active November 22, 2019 11:40
Disable shadowing Ctrl+Alt+Left and Ctrl+Alt+Right in Ubuntu
#!/bin/bash
gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-left "[]"
gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-right "[]"
@ezenkin
ezenkin / go-os-arch.md
Created October 29, 2019 13:44 — forked from asukakenji/0-go-os-arch.md
Go (Golang) GOOS and GOARCH

Go (Golang) GOOS and GOARCH

All of the following information is based on go version go1.8.3 darwin/amd64.

A list of valid GOOS values

(Bold = supported by go out of the box, ie. without the help of a C compiler, etc.)

  • android
  • darwin
@ezenkin
ezenkin / qt5.sh
Last active April 24, 2019 06:47
Fix qmake path for Centos 7
#Put this file to the /etc/profile.d folder
PATH=/path/to/qmake/:$PATH
export PATH