Skip to content

Instantly share code, notes, and snippets.

@orivee
orivee / tmux-cheatsheet.markdown
Created April 17, 2016 15:11 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@orivee
orivee / ChromeAppDownloader.py
Created June 3, 2016 02:38 — forked from arulrajnet/ChromeAppDownloader.py
Python Script to download the Chrome Extensions (CRX) file directly from the google chrome web store.
# -*- coding: utf-8 -*-
"""
Python Script to download the Chrome Extensions (CRX) file directly from the google chrome web store.
Referred from http://chrome-extension-downloader.com/how-does-it-work.php
"""
from __future__ import division
import argparse
import requests
@orivee
orivee / .vimrc
Created August 13, 2016 13:52 — forked from gosukiwi/.vimrc
.vimrc
" ---------------------- USABILITY CONFIGURATION ----------------------
" Basic and pretty much needed settings to provide a solid base for
" source code editting
" don't make vim compatible with vi
set nocompatible
" turn on syntax highlighting
syntax on
" and show line numbers
@orivee
orivee / Xmodmap
Last active August 14, 2016 04:57
my xmodmap configuration
! modify CapsLock to Control, and Shift+CapsLock to CapsLock
! https://wiki.archlinux.org/index.php/Xmodmap#Modifier_keys
clear lock
clear control
clear mod1
add control = Caps_Lock Control_L Control_R
keycode 66 = Control_L Caps_Lock NoSymbol NoSymbol
! swap right control and right alt
! http://askubuntu.com/questions/237564/remap-right-alt-to-behave-as-right-ctrl
@orivee
orivee / html5.vim
Created August 24, 2016 01:19 — forked from gf3/html5.vim
vim HTML5 Syntax File
" Vim syntax file
" Language: HTML (version 5)
" Maintainer: Rodrigo Machado <rcmachado@gmail.com>
" URL: http://rm.blog.br/vim/syntax/html.vim
" Last Change: 2009 Aug 19
" License: Public domain
" (but let me know if you liked it :) )
"
" Note: This file just adds the new tags from HTML 5
" and don't replace default html.vim syntax file
@orivee
orivee / nihtvision
Last active October 14, 2016 08:02
a collecting of colorschemes
# nihtvision
# https://raw.githubusercontent.com/pjhalsli/configs/master/colorschemes/nightvision
# https://www.reddit.com/r/unixporn/comments/56r2qr/bspwm_having_fun_with_colors/
#[colors]
# special
#foreground = #3f3f3f
#foreground_bold = #3f3f3f
#cursor = #3f3f3f
#background = #111010
# black
@orivee
orivee / git_submodules.md
Created November 9, 2016 04:14 — forked from gitaarik/git_submodules.md
Git Submodules basic explanation

Git Submodules basic explanation

Why submodules?

In Git you can add a submodule to a repository. This is basically a repository embedded in your main repository. This can be very useful. A couple of advantages of using submodules:

  • You can separate the code into different repositories.
@orivee
orivee / bash_prompt.sh
Created November 22, 2016 11:22 — forked from insin/bash_prompt.sh
Set color bash prompt according to active virtualenv, git branch and return status of last command.
#!/bin/bash
#
# DESCRIPTION:
#
# Set the bash prompt according to:
# * the active virtualenv
# * the branch/status of the current git repository
# * the return value of the previous command
# * the fact you just came from Windows and are used to having newlines in
# your prompts.
@orivee
orivee / ftpserver.py
Created December 13, 2016 14:58 — forked from scturtle/ftpserver.py
simple ftp server by python
#!/usr/bin/env python2
# coding: utf-8
import os,socket,threading,time
#import traceback
allow_delete = False
local_ip = socket.gethostbyname(socket.gethostname())
local_port = 8888
currdir=os.path.abspath('.')
@orivee
orivee / RSA非对称数据加密算法使用示例
Created December 16, 2016 06:04 — forked from mrhyh/RSA非对称数据加密算法使用示例
RSA非对称数据加密算法使用示例
#include <stdio.h>
#include <string.h>
#include <openssl/rsa.h>
#include <openssl/applink.c>
void print_buf_hex( unsigned char *buf, int len )
{
int i;
for( i = 0; i < len; i++ )