Skip to content

Instantly share code, notes, and snippets.

@codejets
codejets / .vimrc
Created September 3, 2015 19:30
My local .vimrc. Heavily inspired from mdo and alexandre
set nocompatible " Disable vi-compatibility
set t_Co=256
set directory=.,$TEMP
colorscheme xoria256
set guifont=menlo\ for\ powerline:h16
set guioptions-=T " Removes top toolbar
set guioptions-=r " Removes right hand scroll bar
set go-=L " Removes left hand scroll bar
set linespace=15
@codejets
codejets / .aliases
Created September 3, 2015 19:32
.aliases which i import into my bashrc or zshrc
# Get the Git branch
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
# Custom bash prompt
#
# Includes custom character for the prompt, path, and Git branch name.
#
# Source: kirsle.net/wizards/ps1.html
@codejets
codejets / core.css
Last active September 9, 2015 10:34
core.css
.line,
.line-compress {
float: left;
width: 100%
}
a,
button {
cursor: pointer
}
@codejets
codejets / .vimrc_pi
Created September 11, 2015 09:41
.vimrc_pi
" vim:fdm=marker
" Settings -------------------------------------------------------------
" Preamble {{{
" Make vim more useful {{{
set nocompatible
" }}}
@codejets
codejets / .bashrc_git
Created September 14, 2015 07:27
git settings
alias git='hub'
alias g='git status -sb'
alias gh='git hist'
alias gp='git pull'
alias gpr='git pull --rebase'
alias gpp='git pull --rebase && git push'
alias gf='git fetch'
alias gb='git branch'
alias ga='git add'
alias gc='git commit'
@codejets
codejets / sublime-settings
Created March 13, 2016 05:49
Sublime Settings
{
"always_show_minimap_viewport": true,
"auto_complete": true,
"auto_indent": true,
"bold_folder_labels": false,
"caret_style": "phase",
"color_scheme": "Packages/Material Theme/schemes/Material-Theme.tmTheme",
"default_encoding": "UTF-8",
"detect_indentation": true,
"draw_indent_guides": true,
[
{ "keys": [":", "v", "s", "p"], "command": "create_pane", "args": {"direction": "right", "give_focus": true} },
{ "keys": [":", "s", "p"], "command": "create_pane", "args": {"direction": "down", "give_focus": true} },
{ "keys": [":", "b", "d"], "command": "destroy_pane", "args": {"direction": "self"} },
]
@codejets
codejets / Preferences.sublime-settings
Created March 16, 2016 19:39
current sublime preferences
{
"always_show_minimap_viewport": true,
"auto_complete": true,
"auto_indent": true,
"bold_folder_labels": false,
"caret_style": "phase",
"color_scheme": "Packages/Material Theme/schemes/Material-Theme.tmTheme",
"default_encoding": "UTF-8",
"detect_indentation": true,
"draw_indent_guides": true,
@codejets
codejets / constructor.es6.js
Created March 19, 2016 19:51
ES6 implementation of Constructor Pattern
/* We now a have clean class based design like other languages out there.*/
class todo {
constructor(name) {
// Adds the name of the object
this.name = name;
// As Default completed is set to false.
@codejets
codejets / module.js
Created March 19, 2016 20:21
module pattern
// Module Pattern
/*
In Simple terms, Module pattern is a collection of functions in a object literal.
*/
/*
We will make a simple service to store and retrive data from localStorage.
*/
(function() {