script
是一个很好的工具,可以记录终端(http://linuxers.org/article/script-command-line-tool-recordsave-your-terminal-activity)中的所有 Activity 。 Mac上的内置script
可执行文件无法记录 typescript 的计时。我正在尝试编译util-linux软件包(https://github.com/karelzak/util-linux,其中包含linux版本script
),但没有成功:
$ make
make all-recursive
Making all in po
make[2]: Nothing to be done for `all'.
CC lib/libcommon_la-strutils.lo
In file included from lib/strutils.c:16:
./include/strutils.h:77: error: conflicting types for 'strmode'
/usr/include/string.h:168: error: previous declaration of 'strmode' was here
lib/strutils.c:351: error: conflicting types for 'strmode'
/usr/include/string.h:168: error: previous declaration of 'strmode' was here
lib/strutils.c: In function 'size_to_human_string':
lib/strutils.c:442: warning: format '%jd' expects type 'intmax_t', but argument 8 has type 'uint64_t'
make[2]: *** [lib/libcommon_la-strutils.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
Mac上有编译的可执行文件吗?
最佳答案
ttyrec
包括一个针对计时问题的修复程序,并且出于所有意图和目的,都具有相同的功能(在其联机帮助页中描述为script
的派生版本)。可通过brew(brew install ttyrec
)或MacPorts(sudo port install ttyrec
)使用。
关于macos - 在Mac上录制终端的脚本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17942186/