Skip to content

Instantly share code, notes, and snippets.

View nicohq's full-sized avatar

Nico nicohq

  • Kyiv, Ukraine
  • 02:25 (UTC +03:00)
View GitHub Profile
@nicohq
nicohq / clearfix.css
Last active December 17, 2015 18:49 — forked from craigerskine/clearfix.css
.clearfix:before,
.clearfix:after {
content: " ";
display: table;
}
.clearfix:after {
clear: both;
}
@nicohq
nicohq / gist:5697764
Last active December 18, 2015 00:38 — forked from anttti/gist:2017726
hide text under bg
.hide-text {
text-indent: 100%;
white-space: nowrap;
overflow: hidden;
}
@nicohq
nicohq / font-face
Last active December 19, 2015 11:59 — forked from atatos/font-face
@font-face {
font-family: 'MyWebFont';
src: local('MyWebFont');
src: url('webfont.eot'); /* IE9 Compat Modes */
src: url('webfont.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('webfont.woff') format('woff'), /* Modern Browsers */
url('webfont.ttf') format('truetype'), /* Safari, Android, iOS */
url('webfont.svg#svgFontName') format('svg'); /* Legacy iOS */
}
@mixin all-retina-sprites($map, $dimensions: false){
$base-class: sprite-map-name($map);
.#{$base-class}-retina-sprite{
background: sprite-url($map) no-repeat;
@include background-size(ceil(image-width(sprite-path($map)) / 2) auto);
}
@each $sprite in sprite-names($map){
.#{$base-class}-#{$sprite}{
@nicohq
nicohq / gitignore
Created April 21, 2014 17:52
.gitignore
# OS generated files #
######################
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
@nicohq
nicohq / Install_tmux
Last active August 29, 2015 14:08 — forked from simme/Install_tmux
# First install tmux
brew install tmux
# For mouse support (for switching panes and windows)
# Only needed if you are using Terminal.app (iTerm has mouse support)
Install http://www.culater.net/software/SIMBL/SIMBL.php
Then install https://bitheap.org/mouseterm/
# Enable mouse support in ~/.tmux.conf
@nicohq
nicohq / Git_logs
Last active August 29, 2015 14:11
Git log
git log --format='%Cred%h%Creset %s %Cgreen(%cr) %C(blue)<%an>%Creset%C(yellow)%d%Creset' --no-merges
git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@nicohq
nicohq / nodejs-vm.md
Last active August 29, 2015 14:17
Nodejs update

Fortunately there is a very easy way of managing your node version, using the Node binary manager module ‘n’.

1.Check your current version of Node.
$node -v v0.6.12
2.Clear your npm cache
sudo npm cache clean -f
3.Install ‘n’
sudo npm install -g n 4.Upgrade to a later version (this step can take a while) You can specify a particular version like so:
sudo n 0.8.11