333 reputation
2514
bio website datageek.info
location China
age 27
visits member for 3 years, 11 months
seen Nov 17 at 9:24

Simplicity is the ultimate sophistication. — Leonardo Da Vinci

less is more

  • The basic problem is actually very complicated.
  • It's amazing that computers only use 0s and 1s.

handy tools

# download bigfile
$ aria2c -c -k1M -{x,j,s}16 --checksum=md5=dccff28314d9ae4ed262cfc6f35e5153 http://mirrors.zju.edu.cn/ubuntu-releases/14.04/ubuntu-14.04-desktop-amd64.iso

# backup txt files
$ rsync -avzm --include '*/' --include '*.txt' --exclude '*' source/ remote:target/

# transfer big file
$ rsync -hP remote:file .

# convert json to csv
$ jq -r '[.field1,.field2,.field3]|@csv' input.json > output.csv

# convert socks5 to http
$ delegate -P8080 SERVER=http SOCKS=1.2.3.4:1080 ADMIN=[email protected]

# zero-padding file names
$ rename 's/^\d+/sprintf("%02d", $&)/e' [0-9]*

# concat video parts
$ printf "file '%s'\n" part*.mp4 | ffmpeg -f concat -i - -c copy all.mp4

2
× 3
0
× 3
2
0
× 2
2
0
× 2
0
× 4
0
× 2
0
× 3
0
× 2
Stack Overflow 46,263 rep 785132
Super User 3,422 rep 11540
Unix & Linux 431 rep 39
Ask Ubuntu 333 rep 2514
Programming Puzzles & Code Golf 121 rep 4

16 Votes Cast

all time   by type  
16 up 1 question
0 down 15 answer