注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。
启动新会话:
tmux [new -s 会话名 -n 窗口名]
恢复会话:
(gdb) bt | |
#0 0x000000000001956e in ?? () | |
#1 0x00007ffff59f7d69 in SSL_load_error_strings () from /usr/local/lib/python2.7/dist-packages/mysql-vendor/libssl.so.1.0.0 | |
#2 0x00007ffff4fc8c1d in init_ssl () at /build/python2.7-dPs3Rr/python2.7-2.7.12/Modules/_ssl.c:3971 | |
#3 0x000000000051a911 in _PyImport_LoadDynamicModule () at ../Python/importdl.c:53 | |
#4 0x00000000004a4ae1 in import_submodule.lto_priv () at ../Python/import.c:2722 | |
#5 0x00000000004a42c9 in load_next (p_buflen=<synthetic pointer>, buf=0xb1f760 "_ssl", p_name=<synthetic pointer>, | |
altmod=<optimized out>, mod=<optimized out>) at ../Python/import.c:2537 | |
#6 import_module_level.isra.3 (level=0, fromlist=None, globals=<optimized out>, name=<optimized out>) at ../Python/import.c:2246 | |
#7 PyImport_ImportModuleLevel () at ../Python/import.c:2310 |
In [150]: d = u'\xe7\xac\x91\xe5\x8f\xa3\xe5\xb8\xb8\xe5\xbc\x80' | |
In [151]: d | |
Out[151]: u'\xe7\xac\x91\xe5\x8f\xa3\xe5\xb8\xb8\xe5\xbc\x80' | |
In [152]: d.decode('string_escape') | |
--------------------------------------------------------------------------- | |
UnicodeEncodeError Traceback (most recent call last) | |
<ipython-input-152-0f9f72da24b9> in <module>() | |
----> 1 d.decode('string_escape') |
根据Unicode5.0整理如下: | |
1)标准CJK文字 | |
http://www.unicode.org/Public/UNIDATA/Unihan.html | |
2)全角ASCII、全角中英文标点、半宽片假名、半宽平假名、半宽韩文字母:FF00-FFEF | |
http://www.unicode.org/charts/PDF/UFF00.pdf | |
3)CJK部首补充:2E80-2EFF | |
http://www.unicode.org/charts/PDF/U2E80.pdf |
#! /usr/bin/env bash | |
hi_color=$(tput setaf 4) #blue | |
bold=$(tput bold) | |
underline=$(tput smul) | |
normal=$(tput sgr0) | |
read -r -d '' usage << DOC | |
Prints out a table of tmux sessons, windows, and panels. |
After watching Bryan Cantrill's presentation on [Running Aground: Debugging Docker in Production][aground] I got all excited (and strangely nostalgic) about the possibility of core-dumping server-side Python apps whenever they go awry. This would theoretically allow me to fully inspect the state of the program at the point it exploded, rather than relying solely on the information of a stack trace.