Skip to content

Instantly share code, notes, and snippets.

View zorbash's full-sized avatar
👨‍💻
'); DROP TABLE recruiters;

Dimitris Zorbas zorbash

👨‍💻
'); DROP TABLE recruiters;
View GitHub Profile
@zorbash
zorbash / sys_cheatsheet.md
Last active December 14, 2015 08:09
I gathered some linux commands that i use a lot and consider useful.

Useful Commands Cheatsheet

Processes

Interactive Process Viewers

  • top
  • htop
  • atop
@zorbash
zorbash / git_aliases
Created April 2, 2013 11:37
some useful aliases for git
alias.st status
alias.ci commit
alias.co checkout
alias.di diff
alias.br branch
alias.mod ls-files -m
alias.tip log -1
alias.ds diff --cached
alias.sm submodule
alias.line log --oneline
@zorbash
zorbash / .vromerc
Last active December 16, 2015 19:29
My .vromerc
set useletters=1
set hintkeys=dsafrewq,tgcx
// don't run Vrome in those sites
set disablesites=0.0.0.0:5801, localhost:3000
@zorbash
zorbash / xorg.conf.part
Created May 26, 2013 22:11
i3 xorg.conf toggle keyboard layout
Section "InputClass"
Identifier "keyboard-all"
Driver "evdev"
Option "XkbLayout" "us,gr"
Option "XkbOptions" "grp:alt_shift_toggle,grp_led:scroll"
MatchIsKeyboard "on"
EndSection
@zorbash
zorbash / gist:5713028
Created June 5, 2013 10:36
jQuery plugin data parsing function
###
Imports data attributes in form of data-slider-option
into the options
###
parseDataAttributes: ->
# Loop through the data that are not the plugin itself and are in
# the required form (data-slider-option)
for k, v of @$element.data() when k isnt 'plugin_slider' and /^slider/.test k
# separate the option name, here we have it capitalized
option_name = (k.match /(?:slider)(.*)/i)[1]
@zorbash
zorbash / plugin.coffee
Created June 6, 2013 09:08
make a jQuery plugin compatible with ender
$.fn.plugin = fn if $.fn?
$.ender fn, true if $.ender?
@zorbash
zorbash / gist:5721276
Last active December 18, 2015 03:49
Forks and stars / age ratio
{ angular:
{ stars_age_ratio: 8.361512836887439,
forks_age_ratio: 1.7304933104716238 },
ember:
{ stars_age_ratio: 9.336994239940362,
forks_age_ratio: 1.7927237094381803 },
backbone:
{ stars_age_ratio: 14.705360715510952,
forks_age_ratio: 2.8684681847813818 },
batman:
@zorbash
zorbash / config
Created June 14, 2013 14:56
terminator config
[global_config]
geometry_hinting = False
enabled_plugins = CustomCommandsMenu, ActivityWatch, TerminalShot, LaunchpadCodeURLHandler, APTURLHandler, LaunchpadBugURLHandler
title_transmit_bg_color = "#008ec8"
focus = mouse
tab_position = hidden
[keybindings]
[profiles]
[[default]]
scrollbar_position = hidden
@zorbash
zorbash / calculate_bounds.coffee
Last active December 18, 2015 16:39
Function to calculate an element's bounds
calculateBounds: ($element) ->
offset = $element.offset()
width = $element.width()
height = $element.height()
{
nw:
x: offset.left
y: offset.top
ne:
@zorbash
zorbash / gist:5833265
Created June 21, 2013 18:30
.Xdefaults
Xft.antialias: true
Xft.hinting: true
Xft.hintstyle: hintslight
Xft.rgba: rgb
background_color=#222222
*.URxvt.font: xft: Liberation Mono-10
*.URxvt.boldFont: xft: Liberation Mono-10