在Linux上录制终端的操作
在Linux上录制终端的操作
来源 http://blog.51cto.com/stuart/1831570
一、安装基础软件包
|
1
|
[root@test software]# yum install libMagickCore libMagickWand libjpeg-turbo-devel libjpeg-turbo libpng-devel compat-glibc-headers libbsd-devel xdotool -y |
二、安装ttyrec
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
[root@test software]# tar xf ttyrec-1.0.8.tar.gz[root@test software]# unzip -q ttyrec-1.0.8.RHEL5.patch.zip[root@test software]# cd ttyrec-1.0.8[root@test ttyrec-1.0.8]# patch -i ttyrec-1.0.8.RHEL5.patch //打补丁patching file Makefilepatching file ttyrec.c[root@test ttyrec-1.0.8]# makegcc -O2 -DHAVE_openpty -c -o ttyrec.o ttyrec.cgcc -O2 -DHAVE_openpty -c -o io.o io.cgcc -O2 -DHAVE_openpty -o ttyrec ttyrec.o io.o -lutilgcc -O2 -DHAVE_openpty -c -o ttyplay.o ttyplay.cgcc -O2 -DHAVE_openpty -o ttyplay ttyplay.o io.ogcc -O2 -DHAVE_openpty -c -o ttytime.o ttytime.cgcc -O2 -DHAVE_openpty -o ttytime ttytime.o io.o[root@test ttyrec-1.0.8]# lltotal 188-rw-r--r-- 1 root root 4193 Jun 11 2006 io.c-rw-r--r-- 1 root root 371 Jun 11 2006 io.h-rw-r--r-- 1 root root 4256 Jul 23 04:32 io.o-rw-r--r-- 1 root root 654 Jul 23 04:32 Makefile-rw-r--r-- 1 root root 429 Jun 11 2006 README-rw-r--r-- 1 root root 1588 Mar 13 2015 tty2gif.py-rwxr-xr-x 1 root root 20327 Jul 23 09:57 ttygif-rwxr-xr-x 1 root root 15447 Jul 23 04:32 ttyplay-rw-r--r-- 1 root root 1128 Jun 11 2006 ttyplay.1-rw-r--r-- 1 root root 7687 Jun 11 2006 ttyplay.c-rw-r--r-- 1 root root 8648 Jul 23 04:32 ttyplay.o-rwxr-xr-x 1 root root 24505 Jul 23 04:32 ttyrec-rw-r--r-- 1 root root 1454 Jun 11 2006 ttyrec.1-rw-r--r-- 1 root root 935 Jul 23 04:31 ttyrec-1.0.8.RHEL5.patch-rw-r--r-- 1 root root 9789 Jul 23 04:32 ttyrec.c-rw-r--r-- 1 root root 145 Jun 11 2006 ttyrec.h-rw-r--r-- 1 root root 18168 Jul 23 04:32 ttyrec.o-rw-r--r-- 1 root root 441 Jul 23 09:21 ttyrecord-rwxr-xr-x 1 root root 9995 Jul 23 04:32 ttytime-rw-r--r-- 1 root root 432 Jun 11 2006 ttytime.1-rw-r--r-- 1 root root 2459 Jun 11 2006 ttytime.c-rw-r--r-- 1 root root 2152 Jul 23 04:32 ttytime.o[root@jrgc ttyrec-1.0.8]# cp ttyplay ttyrec ttytime /usr/local/bin[root@jrgc ttyrec-1.0.8]# ttyrec //进行录制[root@jrgc ttyrec-1.0.8]# echo "hello,word"hello,word[root@jrgc ttyrec-1.0.8]# exit //结束录制[root@test ttyrec-1.0.8]# ttyplay ttyrecord //本地播放,ttyrecord录制后默认文件,可以自定义文件[root@test ttyrec-1.0.8]# ttyrec test //自定义录制文件[root@test ttyrec-1.0.8]# ll test-rw-r--r--. 1 root root 466 Jul 23 19:28 test |
三、将录制文件转换成GIF
|
1
2
3
4
5
6
7
8
9
10
11
|
[root@test software]# unzip -q seq2gif-master.zip[root@test seq2gif-master]# ./configure[root@test seq2gif-master]# make[root@test seq2gif-master]# make install[root@test ttyrec-1.0.8]# seq2gif -i ttyrecord -o tty.gif[root@test ttyrec-1.0.8]# ll tty.gif-rw-r--r--. 1 root root 28068 Jul 23 19:31 tty.gif附录:git clone https://github.com/saitoha/seq2gifwget http://0xcc.net/ttyrec/ttyrec-1.0.8.tar.gzwget https://codeload.github.com/gist/08c41b8b16ca3b969df4/zip/62767e5f3564346394f5a21bd4fe377d2e05c51c |
四、结果

在Linux上录制终端的操作的更多相关文章
- 如何在 Linux 上录制你的终端操作
导读 录制一个终端操作可能是一个帮助他人学习 Linux .展示一系列正确命令行操作的和分享知识的通俗易懂方法.不管是出于什么目的,从终端复制粘贴文本需要重复很多次,而录制视频的过程也是相当麻烦,有时 ...
- linux之shell终端使用操作快捷键
所谓的shell终端就是桌面右键里面的打开终端那个终端 敲命令是一件很有趣的事,可是有时候我们会遇到一些很麻烦的事 例如,命令太长导致敲完后一大串字符可读性低,想把vi filename 快速改为ca ...
- linux文件或文件夹常见操作,排查部署在linux上程序问题常用操作
创建文件夹 mkdir [-p] DirName [ 在工作目录下,建立一个名为 A 新的子目录 : mkdir A 在工作目录下的 B目录中,建立一个名为 T 的子目录: 若 B 目录不存在,则 ...
- 如何在linux下录制terminal操作?
相关包: ttyrec: ttyrec is a tty recorder. Recorded data can be played back with the included ttyplay co ...
- 在Windows上使用终端模拟程序连接操作Linux以及上传下载文件
在Windows上使用终端模拟程序连接操作Linux以及上传下载文件 [很简单,就是一个工具的使用而已,放这里是做个笔记.] 刚买的云主机,或者是虚拟机里安装的Linux系统,可能会涉及到在windo ...
- 提升效率的Linux终端快捷操作汇总
很多普通 Linux 桌面用户都对使用终端感到排斥和恐惧,其实它没大家想的那么复杂,很多常见操作都可以直接在终端中进行,如:安装软件.升级系统等. 无论你是新手还是 Linux 终端使用的老鸟,系统极 ...
- Linux终端快捷操作汇总
定位单词 在长段的命令中,使用 Ctrl + ← 和 Ctrl + → 可快速将光标定位到命令中单词的首字母或末尾,实现在各单词之间的快速跳动定位. 你可以试着在终端中输入 apt-get insta ...
- jmeter操作数据库,分布式,在Linux上运行
jmeter操作数据库: 1.在测试计划中导入数据库jar包 2.添加链接数据库信息 3.mysql:jdc:mysql://192.168.1.116:3307/bugfree?allowMulti ...
- C++的标准库函数默认都是操作字节,而不是字符,非常痛苦,所以引入了u16string和u32string(Linux上的wchar_t是32位的原因,utf16对unicode的支持是有缺陷的)good
时至今日,字符串使用unicode已经是不需要理由的常识,但对一些有着悠久历史的编程语言来说,这仍然是个头痛的问题.如果抛开第三方库的支持,C++其实并不能实际有效地支持unicode,即使是utf8 ...
随机推荐
- XCode快捷键使用
:first-child{margin-top:0!important}.markdown-body>:last-child{margin-bottom:0!important}.markdow ...
- .Net Core爬虫爬取妹子网图片
现在网上大把的Python的爬虫教程,很少看见有用C#写的,正好新出的.Net Core可以很方便的部署到Linux上,就用妹子图做示范写个小爬虫 在C#下有个很方便的类库 HtmlAgilityPa ...
- webkit几种内核版本的优劣对比总结
01.Open-Webkit-Sharp 默认不存在JS对话框,如果需要显示alert box,则需要在ShowJavaScriptAlertPanel进行捕捉,然后显示对话框: 02.Open-We ...
- Linux实战教学笔记15:用户管理初级(下)
第十四节 用户管理初级(下) 标签(空格分隔): Linux实战教学笔记-陈思齐 ---更多资料点我查看 1,用户查询相关命令id,finger,users,w,who,last,lastlog,gr ...
- PHP生成ZIP压缩文件
PHP生成ZIP压缩文件 /* * 生成zip压缩文件 * $sourceDir:被压缩的文件夹或文件 * $outFileName:输出的压缩文件名称 * */ function createZip ...
- jquery横向手风琴效果
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...
- 【转载】CentOS7.0下安装Telnet
1..先检查CentOS7.0是否已经安装以下两个安装包:telnet-server.xinetd.命令如下: # rpm -qa telnet-server # rpm -qa xinetd 如果没 ...
- python 函数 闭包 (节省内存空间 html 获取网页的源码)
#闭包:嵌套函数,内部函数调用外部函数的变量 # def outer(): # a = 1 # def inner(): # print(a) # inner() # outer() def oute ...
- Permute Digits 915C
You are given two positive integer numbers a and b. Permute (change order) of the digits of a to con ...
- mac上MySQLdb问题解决
早上有个同学问题python访问mysql的问题,之前的写得脚步突然不能运行了,找了很多文章总算解决问题了O(∩_∩)O哈哈~,希望下次不要浪费这么多时间搞这么坑的问题了. mac上MySQLdb ...