This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import sys | |
from distutils.sysconfig import get_python_lib | |
SITE_PACKAGES = get_python_lib() | |
BUILDOUT_PTH = os.path.join(SITE_PACKAGES, 'buildout.pth') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; enable melpa | |
(require 'package) ;; You might already have this line | |
(add-to-list 'package-archives | |
'("melpa" . "https://melpa.org/packages/")) | |
(when (< emacs-major-version 24) | |
;; For important compatibility libraries like cl-lib | |
(add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))) | |
(package-initialize) ;; You might already have this line | |
;; /enable melpa |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; -*- mode: emacs-lisp -*- | |
;; This file is loaded by Spacemacs at startup. | |
;; It must be stored in your home directory. | |
(defun dotspacemacs/layers () | |
"Configuration Layers declaration. | |
You should not put any user code in this function besides modifying the variable | |
values." | |
(setq-default | |
;; Base distribution to use. This is a layer contained in the directory |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/env python2 | |
from urllib2 import urlopen | |
URL = 'https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts' | |
hosts = urlopen(URL) | |
output = [] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call plug#begin('~/.config/nvim/plugged') | |
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } | |
Plug 'neomake/neomake' | |
Plug 'kien/rainbow_parentheses.vim' | |
Plug 'scrooloose/nerdtree' | |
Plug 'Yggdroot/indentLine' | |
Plug 'groenewege/vim-less' | |
Plug 'flazz/vim-colorschemes' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import sys | |
from urllib2 import urlopen | |
from subprocess import call | |
URL = 'http://icanhazip.com/' | |
IP_FILE = '/tmp/lastip.txt' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
((nil . ((pyvenv-workon . "buildout-folder-name")))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from functools import reduce | |
from functools import wraps | |
def log_in_out(func): | |
@wraps(func) | |
def wrapper(*args, **kwargs): | |
result = func(*args, **kwargs) | |
print('{} in: {}, out: {}'.format(func.__name__, args, result)) | |
return result |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssh -f -g -L 3689:127.0.0.1:3689 -N username@hostname | |
avahi-publish-service sharename _daap._tcp 3689 & |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install uwsgi>=2.0.15 (requires build-essential and python-dev) | |
# adding it to eggs should also work, assuming you have gcc | |
[buildout] | |
parts += | |
instance | |
uwsgi-app | |
uwsgi-run | |
[uwsgi-run] |