start new:
tmux
start new with session name:
tmux new -s myname
| # -*- text -*- | |
| # SOFTBANK BB Corp. E-WMTA | |
| # $Id$ | |
| VENDOR SoftBankBB 22197 | |
| BEGIN-VENDOR SoftBankBB | |
| ATTRIBUTE SoftBankBB-Unknown 1 octets | |
| ATTRIBUTE SoftBankBB-E_WMTA-Vendor 2 string | |
| ATTRIBUTE SoftBankBB-E_WMTA-Version 3 string |
| #!/usr/bin/env python | |
| #-*- coding: utf-8 -*- | |
| ''' | |
| Copyleft (c) 2016 breakwa11 | |
| https://github.com/breakwa11/shadowsocks-rss | |
| ''' | |
| import logging | |
| import socket |
| #!/bin/bash | |
| #requires: socat | |
| #author: fangpsh | |
| #关于采集的Haproxy指标和报警阈值设置请参考:https://github.com/iask/haproxymon | |
| set -eu | |
| STATS_SOCKET="/var/lib/haproxy/stats" | |
| HOST=`cat /etc/hostname` | |
| DATE=`date +%s` | |
| tmp_info="/tmp/haproxy_info" |
| [General] | |
| loglevel = notify | |
| skip-proxy = 127.0.0.1, 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12, 100.64.0.0/10, localhost, *.local, ::ffff:0:0:0:0/1, ::ffff:128:0:0:0/1 | |
| bypass-tun = 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12 | |
| # dns-server = 119.29.29.29,223.5.5.5,114.114.115.115 | |
| # external-controller-access = [email protected]:6155 | |
| # ipv6 = true | |
| // REMEMBER TO CHANGE THE external-controller-access' PASSWORD |
| [General] | |
| skip-proxy = 127.0.0.1, 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12, 100.64.0.0/10, localhost, *.local, ::ffff:0:0:0:0/1, ::ffff:128:0:0:0/1 | |
| bypass-tun = 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12 | |
| # dns-server = 119.29.29.29, 223.5.5.5, 114.114.114.114 | |
| loglevel = notify | |
| [Proxy] | |
| BJ-All = custom | |
| BJ-HK-Azure = custom | |
| BJ-US-Azure = custom |
| # 用于view的装饰器 | |
| from ..utils.permissions import VisitorPermission | |
| @bp.route('/signin', methods=['GET', 'POST']) | |
| @VisitorPermission() | |
| def signin(): | |
| """登陆""" | |
| form = SigninForm() | |
| if form.validate_on_submit(): | |
| signin_user(form.user) |
| /* | |
| gulpfile from one of my React applications which has a gulp --production build | |
| set up. | |
| Assumptions: | |
| 1. All your own .js/.jsx modules are somewhere under ./src, have unique | |
| filenames and use Node.js-style requires WITHOUT any path information, just | |
| the name of another module somewhere under ./src |
| #! /usr/bin/env python | |
| """{escher} -- one-file key-value storage. | |
| What? | |
| This is a toy application to manage persistent key-value string data. | |
| The file {escher} is *both* the application and its data. | |
| When you run any of the commands below, the file will be executed and, | |
| after data change, it will rewrite itself with updated data. | |
| You can copy the file with whatever name to create multiple datasets. |
| import os.path | |
| import contextlib | |
| import hashlib | |
| from flask import Flask | |
| from flask.helpers import safe_join | |
| # Injects an "h" parameter on the URLs of static files that contains a hash of | |
| # the file. This allows the use of aggressive cache settings on static files, | |
| # while ensuring that content changes are reflected immediately due to the | |
| # changed URLs. Hashes are cached in-memory and only checked for updates when |