computer:bash_snippets
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
computer:bash_snippets [2018-10-22 00:32] – [Play YouTube Playlists] skrupellos | computer:bash_snippets [2020-11-18 18:11] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 2: | Line 2: | ||
http:// | http:// | ||
+ | ===== Git ===== | ||
+ | <code bash> | ||
+ | git checkout | ||
+ | </ | ||
===== Play YouTube Playlists ===== | ===== Play YouTube Playlists ===== | ||
<code bash> | <code bash> | ||
Line 11: | Line 15: | ||
--playlist-end 19 \ | --playlist-end 19 \ | ||
' | ' | ||
- | mkvmerge -o all_001-019.mkv id∗ | + | mkvmerge -o all_001-019.mkv \[ id_{1..19}\ |
mpv --save-position-on-quit all_001-019.mkv | mpv --save-position-on-quit all_001-019.mkv | ||
</ | </ | ||
+ | |||
+ | <WRAP center round important 60%> | ||
+ | * Achte auf '' | ||
+ | * Der glob '' | ||
+ | </ | ||
+ | |||
+ | |||
+ | Geeignete Formate finden: | ||
+ | <code bash> | ||
+ | youtube-dl -F ' | ||
+ | grep -E ' | ||
+ | sort -nr | \ | ||
+ | uniq -w 10 -c | \ | ||
+ | sort -nrs | ||
+ | </ | ||
+ | |||
+ | <WRAP center round important 60%> | ||
+ | Achte auf die Hardware-Beschleunigung (siehe '' | ||
+ | </ | ||
===== Order files and directories recursive by date ===== | ===== Order files and directories recursive by date ===== | ||
Line 126: | Line 149: | ||
</ | </ | ||
- | ===== Network monitoring ===== | ||
- | http:// | ||
- | ^ Programm ^ Per Interface ^ Per Stream ^ Per Process ^ Non Root ^ Kommentar ^ | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | |||
- | |||
- | * '' | ||
- | * '' | ||
- | |||
- | Iperf server: http:// | ||
===== diff & patch ===== | ===== diff & patch ===== | ||
* '' | * '' | ||
Line 212: | Line 217: | ||
</ | </ | ||
</ | </ | ||
+ | |||
+ | ====== CUPS ====== | ||
+ | Delete all learned Network printers: | ||
+ | <code bash> | ||
+ | lpstat -s | \grep ///dev/null | cut -c 12- | cut -d: -f1 | xargs -n1 -- lpadmin -x | ||
+ | </ | ||
+ | |||
====== Zu schlecht für ein dotfile ====== | ====== Zu schlecht für ein dotfile ====== | ||
Hier sind scripte, die zwar eine nette Idee, aber viel zu schlecht für ein dotfile sind. | Hier sind scripte, die zwar eine nette Idee, aber viel zu schlecht für ein dotfile sind. | ||
Line 248: | Line 260: | ||
</ | </ | ||
+ | < | ||
+ | smartctl -x /dev/sda | ||
+ | </ | ||
+ | <code python> | ||
+ | for i in [2, 1.9, 1.5, 1.1, None, 0, None, -1.1, -1.5, -1.9, -2]: | ||
+ | print(' | ||
+ | </ | ||
+ | < | ||
+ | 2.0: ceil = 2 || round = 2 | int(i+.5) = 2 || floor = 2 | int = 2 || int(i)+1 = 3 | int(i)-1 = 1 | ||
+ | 1.9: ceil = 2 || round = 2 | int(i+.5) = 2 || floor = 1 | int = 1 || int(i)+1 = 2 | int(i)-1 = 0 | ||
+ | 1.5: ceil = 2 || round = 2 | int(i+.5) = 2 || floor = 1 | int = 1 || int(i)+1 = 2 | int(i)-1 = 0 | ||
+ | 1.1: ceil = 2 || round = 1 | int(i+.5) = 1 || floor = 1 | int = 1 || int(i)+1 = 2 | int(i)-1 = 0 | ||
+ | --------------------------------------------------------------------------------------------------------- | ||
+ | 0.0: ceil = 0 || round = 0 | int(i+.5) = 0 || floor = 0 | int = 0 || int(i)+1 = 1 | int(i)-1 = -1 | ||
+ | --------------------------------------------------------------------------------------------------------- | ||
+ | -1.1: ceil = -1 || round = -1 | int(i+.5) = 0 || floor = -2 | int = -1 || int(i)+1 = 0 | int(i)-1 = -2 | ||
+ | -1.5: ceil = -1 || round = -2 | int(i+.5) = -1 || floor = -2 | int = -1 || int(i)+1 = 0 | int(i)-1 = -2 | ||
+ | -1.9: ceil = -1 || round = -2 | int(i+.5) = -1 || floor = -2 | int = -1 || int(i)+1 = 0 | int(i)-1 = -2 | ||
+ | -2.0: ceil = -2 || round = -2 | int(i+.5) = -1 || floor = -2 | int = -2 || int(i)+1 = -1 | int(i)-1 = -3 | ||
+ | </ |
computer/bash_snippets.1540161150.txt.gz · Last modified: 2020-11-18 18:10 (external edit)