Command Line Tools

本文汇总了一系列实用的命令行技巧,包括视频转GIF、文件传输、启动时间显示、端口查看、启动命令设置、Vim编辑器使用技巧、JAR文件内文件修改、大文件创建等,适用于日常开发及系统管理。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

convert a video to gif

mkdir frames
ffmpeg -i input -vf scale=320:-1:flags=lanczos,fps=10 frames/ffout%03d.png
convert -loop 0 frames/ffout*.png output.gif
复制代码

copy file use ssh

scp -P port /path/to/file username@a:/path/to/destination
scp -P port username@b:/path/to/file /path/to/destination
复制代码

terminal startup time

Put
set -x
at the top and
set +x
at the bottom of both files ~/.profile and ~/.bashrc.
复制代码

show open ports

netstat -tlp | grep LISTEN
复制代码

startup command

/etc/rc.local
复制代码

use Vim edit Hex file

  • :%!xxd to switch into hex mode
  • :%!xxd -r to exit from hex mode

modify a file inside a jar

jar uf jar-file input-file(s)
复制代码

make a large file

dd if=/dev/zero of=outputFile bs=2G count=1
复制代码
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值