注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。
启动新会话:
tmux [new -s 会话名 -n 窗口名]
恢复会话:
/** | |
* 判断两个版本字符串的大小 | |
* @param {string} v1 原始版本 | |
* @param {string} v2 目标版本 | |
* @return {number} 如果原始版本大于目标版本,则返回大于0的数值, 如果原始小于目标版本则返回小于0的数值。0当然是两个版本都相等拉。 | |
*/ | |
function compareVersion(v1, v2) { | |
var _v1 = v1.split("."), | |
_v2 = v2.split("."), |
// 利用ES6的Set数据结构来数组去重 | |
// 方法1 | |
let array = [1,2,2,2,1,2,2,3,4]; | |
function dedupe(array) { | |
return Array.from(new Set(array)); | |
} | |
var a = dedupe(array); | |
console.log(a);//[ 1, 2, 3, 4 ] | |
//方法二 利用语法糖 ... | |
// 其实就是内部的一个for..of 循环 |
hintcharacters = 'sadfjklewcmpgh'; | |
let fullpagescrollpercent = 100 | |
let lastactivetablimit = 50; | |
let lastclosedtablimit = 50; | |
let scrollduration = 25 | |
let scrollstep = 65 | |
let zoomstep = 15 | |
let homeurl = "http://google.com"; | |
let mapleader = "," | |
let newtaburl = "http://google.com" |
# If you come from bash you might have to change your $PATH. | |
# Golang config | |
export GOPATH=$HOME/go | |
export PATH=$HOME/bin:/usr/local/bin:$PATH:$HOME/qiniu:/usr/local/opt/go/libexec/bin:$GOPATH/bin | |
export ARIA_PATH=$HOME/.aria2 | |
export JAVA_HOME='/Library/Java/JavaVirtualMachines/jdk1.8.0_181.jdk/Contents/Home' | |
export CLASSPATH=$CLASSPATH:$JAVA_HOME/lib/algs4.jar | |
export ZPLUG_HOME=/usr/local/opt/zplug | |
source $ZPLUG_HOME/init.zsh | |
# export ANDROID_HOME=$HOME/Library/Android/sdk |
{ | |
"type": 0, | |
"data": { | |
"transaction_id": "82754ee125b14dc09295f455612a555e4613f05fbaa60ae6a3bba9cfd523fcf0", | |
"processed": { | |
"elapsed": 2265, | |
"receipt": { | |
"status": "executed", | |
"net_usage_words": 18, | |
"cpu_usage_us": 2265 |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Document</title> | |
</head> | |
<body> | |
<script id="jsbin-javascript"> | |
console.clear(); |
Sometimes you want to have a subdirectory on the master
branch be the root directory of a repository’s gh-pages
branch. This is useful for things like sites developed with Yeoman, or if you have a Jekyll site contained in the master
branch alongside the rest of your code.
For the sake of this example, let’s pretend the subfolder containing your site is named dist
.
Remove the dist
directory from the project’s .gitignore
file (it’s ignored by default by Yeoman).