Skip to content

Instantly share code, notes, and snippets.

View fire9's full-sized avatar
🏠
Working from home

fire9 fire9

🏠
Working from home
View GitHub Profile
@fire9
fire9 / Supervisor.md
Created December 25, 2017 09:21
Supervisor Note

Supervisor

sudo apt-get update
sudo apt-get install -y supervisor
supervisorctl help
supervisorctl reread

>Configuration /etc/supervisor/supervisord.conf

@fire9
fire9 / setup_env_python.md
Created December 25, 2017 09:22
Python 环境搭建

Python 环境搭建

针对 Ubuntu 系统搭建

更新与升级软件包

$ sudo aptitude -y update
$ sudo aptitude -y upgrade
$ sudo apt-get -y install build-essential
$ sudo apt-get -y install libsqlite3-dev
@fire9
fire9 / st3cs.md
Created December 25, 2017 10:17
Sublime Text3 Cheat Sheet

Sublime Text3 Cheat Sheet

Text Editing Beginner

快捷键 操作
⌃X Cut line
⌃↵ Insert line after
⇧⌃↵ Insert line before
⇧⌃UP Move line/selection up
⇧⌃DOWN Move line/selection down
@fire9
fire9 / tmuxcs.md
Created December 25, 2017 10:18
tmux cheat sheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@fire9
fire9 / auth_proxy.md
Created December 27, 2017 14:58
给代理服务器增加认证访问

给代理服务器增加认证访问

在做代理服务器的时候如果没有认证功能,会导致很多人来是使用这个代理服务器,为了防止滥用,所以增加个认证功能。

创建Password文件

sh -c "echo -n 'proxy:' >> /etc/nginx/.htpasswd"
@fire9
fire9 / pythonformac_tips.md
Last active December 27, 2017 15:39
Mac Python 命令行补全

Mac Python 命令行补全

#!/usr/local/bin/env python
# -*- coding: utf-8 -*-


import sys
import readline
import rlcompleter
@fire9
fire9 / yarncommand.md
Created December 27, 2017 15:40
YARN 常用命令

YARN 常用命令

安装 yarn

$ curl -o- -L https://yarnpkg.com/install.sh | bash

yarn 相关命令

$ yarn version
@fire9
fire9 / motd.txt
Created January 30, 2018 08:42
motd
_oo8oo_
o8888888o
88" . "88
(| -_- |)
0\ = /0
___/'==='\___
.' \\| |// '.
/ \\||| : |||// \
/ _||||| -:- |||||_ \
@fire9
fire9 / vps_init_setup.md
Created March 10, 2018 04:14
vps_init_setup

echo "flow8" > /etc/hostname hostname -F /etc/hostname

echo "106.187.35.226 flow8.net flow8" >> /etc/hosts

sudo apt-get install -y exim4 gem install bundler

[apc] apc.enabled = 1

# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->