This repository has been archived by the owner on Jun 15, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
/
.bash_history
1874 lines (1874 loc) · 74.1 KB
/
.bash_history
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
./configure # packaging
./configure --help | less # packaging
./gradlew # java build project
./setup.py test
~/dev/flickrmirrorer/flickrmirrorer.py ~/pictures
~/dev/img2vcard/img2vcard.sh photo.jpg > photo.vcf # convert image vcard
~/dev/meta2jpeg/meta2jpeg.sh ./*.CR2 # copy metadata graphics image
~/dev/schemaspy2svg/schemaspy2svg.sh ~/db # database graphics convert svg
~/dev/tilde/scripts/git-mergerequest.sh master # create pull request
~/dev/vcard/format-TEL.sh -i ~/contacts/*.vcf # format telephone number vcard
~/dev/vcard/sort-lines.sh ~/dev/vcard/sorts/Gmail.re ~/contacts/*.vcf # sort vcard files
~/dev/vcard/split.sh ~/contacts/*.vcf # split vcard files
~/dev/xterm-color-count/xterm-color-count.sh # xterm color
~/dev/xterm-color-count/xterm-color-count.sh -v # xterm color
COMPOSE_HTTP_TIMEOUT=99999999 docker-compose logs -f --tail=10
GIT_CURL_VERBOSE=1 git pull # debug
IFS=':' read -a paths <<< "$PATH" # tokenize array
PATH=$(IFS=':'; echo "${paths[*]}")
PS1='\$ ' # prompt demo
TAGS=all guard
TAGS="$USER" guard
abcde -Q cddb -o flac # rip audio cd
acpi_listen # events power configuration
adb devices # list android
adb push PATHS /sdcard/ # upload file directory recursive android
adb reboot bootloader # fastboot android
adb shell logcat -T 10 # list follow android log
adb shell # android
ag REGEX # search recursive
alias ls
align_image_stack -vl -a aligned ./*.jpg # graphics
alsamixer # audio input output volume
amixer set 'Beep' 0% mute || amixer set 'PC Beep' 0% mute || amixer set 'PC Speaker' 0% mute # mute speaker
amixer --card 2 # list audio hardware device configuration
aplay recording.wav # audio output
aplay --list-devices # list audio hardware
aplay --list-pcms # list audio output speaker
appres URxvt # list x application resource database
appres XTerm # list x application resource database
apropos REGEX # help man
apropos --exact mv # help man
archlinux-java status
arecord --duration 5 --format dat recording.wav # record audio file
arecord --format dat | aplay # test audio input capture output playback default microphone speakers
arecord --list-devices # list audio input capture microphones
arp -a # network list arp cache
avahi-browse --terminate --all # network services scan local remote
avahi-browse --terminate --ignore-local _workstation._tcp # network tcp workstations scan remote
avahi-browse-domains --terminate # network domains scan
avconv -i input.mov -codec copy -ss 15 output.mov # video cut
avconv -i input.mov -codec:video libx264 -codec:audio copy -filter transpose=clock output.mov # video rotate
avconv -i %04d.jpg -vcodec libx264 -bf 0 -crf 12 -an -r 25 -s hd1080 timelapse2.mp4 # video convert
awesome --check # configuration verify parse
awk '{ print $22 }' /proc/1/stat # process start time jiffies since boot
basename "$(find -L /dev/disk/by-uuid -samefile /dev/DISK)" # disk uuid
basename -- PATH.dat .dat # file name extension
basename -- "$PWD" # current directory name
bashdb example.sh # debug shell script
bash -o noexec ~/.bash_history # verify shell script syntax
bash --noprofile --norc -o xtrace # test trace shell
bc --mathlib <<< 'e(1)' # calculator math e power
bc <<< '2+2' # calculator math
bc <<< 'scale = 10; sqrt ( 2 )' # calculator math precision scale float decimal
bg # background job
bind -P | rg --fixed-strings ' can be found on ' | perl -pe 's/((?<!\\)(?:\\\\)*)\\C/\1Ctrl/g;s/((?<!\\)(?:\\\\)*)\\e/\1Esc,/g' # keyboard shortcuts
bind -p | rg --invert-match --regexp '^$' --regexp '^#' --regexp 'self-insert$' | sed "s/\(.*\)/bind '\1'/" | tr --squeeze-repeats '\n' ';' # shortcuts code
bluetoothctl
borg create --progress --remote-path=PATH --stats --verbose HOST:REPOSITORY/::$(date +%Y-%m-%d) DIRECTORY # backup directory
borg delete --remote-path=PATH HOST:REPOSITORY/::$(date +%Y-%m-%d) # remove backup
borg init --encryption=repokey --remote-path=PATH HOST:REPOSITORY
bsdtar --list --file /boot/initramfs-linux.img | less # print kernel image files
builtin # bash list
bunzip2 file.bz2 # compression bzip
cargo build # rust
cargo init --bin project-name # rust project create
cargo test # rust build test
cat ~/contacts/*.vcf > ~/contacts.vcf # concatenate vcard
cat /dev/zero > /tmp/ramdisk.XXXXXXXXXX/full.log # fill ramdisk partition file tmpfs
cat /etc/papersize # print
cat /etc/*release # os
cat /proc/cmdline # boot command
cat /proc/cpuinfo # hardware
cat /proc/devices # hardware
cat /proc/filesystems # hardware
cat /proc/misc # hardware
cat /proc/stat # hardware
cat /proc/sys/dev/cdrom/info
cat /proc/sys/kernel/pid_max # process
cat /proc/vmstat # hardware
cbatticon --help-all
cbatticon --list-power-supplies # battery
cd - # back
cd "$(mktemp --directory)" # create temporary directory
certutil # help
checkbashisms ./*.sh
chfn --full-name "John Doe"
chmod go= ~/.ssh/id_rsa # permission
chmod u+x example.sh # permission executable
cmp --print-bytes "$(which arch)" "$(which uname)" # binary diff
coffee -v # coffeescript
comm -23 --nocheck-order <(alias -p) <(bash -lc 'alias -p') # list session aliases
comm -23 <(rg --no-filename ^FN: ~/contacts.vcf | sort --unique) <(rg --no-filename ^FN: ~/contacts/*.vcf | sort --unique) # compare vcard names
convert -density 150 -quality 100 input.pdf output.jpg # graphics extract image
convert ./name-*.gif name-%04d.png # format number graphics
convert ./*.jpg output.pdf # graphics combine image
coredumpctl dump PID > coredump.bin # trace segfault
coredumpctl gdb PID <<< bt # trace segfault
coredumpctl list # segfault
count . # filesystem
coverage help
coverage report --include='*/*' --fail-under=100 # python test coverage
coverage run setup.py test # python test coverage
cppcheck foo.c # lint c code
cp file{,.orig} # filesystem
cp --archive dir target # recursive owner permissions
createdb --template template0 --username username dbname # postgresql
cronlist
cronlist --help
cronlist --system
cronlist --to '23:59:59'
crontab -e # edit
crontab -l # list
csplit --prefix contact- --suffix-format %02d.vcf --elide-empty-files --quiet ~/contacts.vcf '/BEGIN:VCARD/' '{*}' # split vcard file
csplit --prefix header- --suffix-format %02d.txt --elide-empty-files --quiet headers.txt '/----------------------------------------------------------/1' '{*}' # split file
cssh server{1,2,3} # ssh multiple servers
csvtool col 3 example.csv # csv column
csvtool --help | less
curl dict://dict.org/d:word # language dictionary
curl --request POST --header 'Content-Type: application/json' --data '{"foo": 1}' https://example.org/ # post web api
cut --delimiter=':' --fields=1 /etc/group | sort
darktable & # 2d image editor raw
date +%FT%T.%N # iso time
date +%Y-%m-%dT%H:%M:%S # iso time
date --date="6 months ago" # past time
date --date="6 months" # future time
date --date="2001-09-09 03:46:40+02:00" +%s # convert timestamp
date --date="Friday" # today future midnight
date --date="Monday" # today future midnight
date --date="Saturday" # today future midnight
date --date="Sunday" # today future midnight
date --date="Thursday" # today future midnight
date --date="Tuesday" # today future midnight
date --date="Wednesday" # today future midnight
date --date="now" # time
date --date="yesterday" # time
date --rfc-3339=ns --date="2001-02-03T04:05:06.7 + 1 year 2 months 3 days 4 hours 5 minutes 6.7 seconds" # dst time iso
date --rfc-3339=seconds --date="@1000000000" # convert timestamp
dd if=/dev/cdrom of=cdrom.iso # rip cd
dd if=/dev/null of=/file/to/truncate seek=1 bs=1024 # truncate file bytes
dd if=/dev/urandom bs=1kB count=1 | ent # calculate entropy
dd if=/dev/zero of="${sandbox}/zeros.bin" bs=1000 count=5 # create file size
deactivate # virtualenv
declare # variables functions
declare -F # functions
declare -a # arrays
declare -f function_name # function definition
declare -p # color variables functions
deluge & # bittorrent gui
df --human-readable # filesystem list all
df --human-readable . # filesystem current directory
df --portability . | tail --lines 1 | cut --delimiter ' ' --fields 1 | rg --fixed-strings --invert-match --line-regexp --regexp '-' # directory partition
dia --help
difff --help
diffoscope --text-color=always OLD NEW | less --RAW-CONTROL-CHARS # file directory
diff --unified file{.orig,} # files
diff --unified <(hexdump -C /bin/uname) <(hexdump -C /usr/bin/arch)
diff --unified <(sudo sh -c env | sort) <(sudo -i sh -c env | sort) # environment variables root login shell
digikam & # photo manager
dig example.org mx # dns email lookup internet network
dig example.org # dns lookup internet network
dirname -- "$PWD" # parent directory
disown %+ # nohup last job background process
dmesg --color=always | less -r # debug os startup
docker build .
docker images # list
docker info
docker network inspect host # config
docker ps --all # list container
docker pull base/archlinux
docker run --interactive --rm --tty ubuntu:14.04 /bin/bash # shell container
docker system prune # clean remove container image
docker-compose build && docker-compose up -d
docker-compose run --rm test bash # shell container
dos2unix example.txt # convert newline
dotty graph.dot # graphics
dot -O -Tsvg ./*.dot # graphics
dot -Tsvg graph.dot # graphics
dot -V
drive=/dev/sdX && [[ -b "$drive" ]] && ! rg "^${drive}" /proc/mounts && sudo dd bs=4M if=ISO of="$drive" status=progress oflag=sync # iso write disk
dropdb --username username dbname # postgresql
du --si --summarize . # disk size
dvdbackup --mirror --input=/dev/cdrom --output="$HOME" # rip dvd
echo 0 61 62 63 | xxd -revert # hex dump convert string character byte
echo example | xclip # clipboard mouse copy
echo example | xclip -selection clipboard # clipboard keyboard copy
echo return _VERSION | awesome-client # lua version
echo !!:q | xclip -selection clipboard # copy previous command
echo "body" > ~/.events/summary # notify
echo "$OSTYPE"
echo "$PATH" | tr ':' $'\n' # user path
echo "$PROMPT_COMMAND" # shell
echo "$REPLY" # read
echo "$TERM" # shell
echo "$WINEPREFIX"
echo "${COLUMNS}x${LINES}" # terminal size dimensions
echo "${PIPESTATUS[@]}" | tr --squeeze-repeats ' ' + | bc # array sum
echo "${paths[0]}" # array
echo "${paths[@]: -1}" # array
echo "${paths[@]}" # array
echo $BASHPID # shell subshell pid
echo $$ # shell pid
echo $? # exit code
echo 'LC_PAPER="en_GB.UTF-8"' | sudo tee --append /etc/environment # print
eject # hardware cd dvd
enable -a # builtins
enable -n # disabled builtins
env # variable
env - HOME="$HOME" LOGNAME="$USER" PATH="/usr/bin:/bin" SHELL="$(which sh)" command # emulate cron command
env --ignore-environment bash -c 'printf "%s\n" "${?+?=$?}" "${#+#=$#}" "${*+*=$*}" "${@+@=$@}" "${-+-=$-}" "${!+!=$!}" "${_+_=$_}" "${$+$=$$}"; env'
eval "$traps" # signal
eval "$(resize -s 24 80)" # terminal
eval "$(ssh-agent)" && ssh-add
exec "$SHELL" # replace
exiftool -AllDates+='-00:01:00 00:00:00' . # exif adjust date time images
exiftool -common . # exif images directory files
exit
exiv2 print IMG_1234.exv # metadata
expand --tabs=4 example.txt # convert tab space
export DISPLAY=:0.0 # remote x display
export key=~/.ssh/id_rsa_service_name && umask 0077 && ssh-keygen -b 4096 -f "$key" -t rsa && openssl pkcs8 -topk8 -v2 des3 -in "$key" -out "${key}.pk8" && shred --remove "$key" && mv --no-clobber "${key}.pk8" "$key" && unset key # create encrypted private public rsa pkcs8 ssh key pair
extundelete --help
ex -c '1' -c '?^[[:space:]]*[^[:space:]#]?' -c $'a\n# New comment' -c 'wq' ~/.bashrc # insert after last match
facter id # user
facter # hardware os
facter --help
fastboot devices # list android
fceux ROM # nes nintendo emulator game
fc # edit command history
fc -l # list commands history
fc -s # execute last command history
fc-cache # refresh fonts
fc-list | sort # list fonts
feh --auto-zoom --scale-down --recursive . # images viewer resize
feh --fullscreen --hide-pointer ./* # images viewer
ffmpeg -activation_bytes ACTIVATION_BYTES -i input.aax -vn -c:a copy output.mp4 # aax audio convert
ffmpeg -i input.mov -vcodec copy -acodec copy -ss 00:00:00 -t 00:01:00 output.mov # video split
ffmpeg -i %04d.jpg -vcodec libx264 -bf 0 -crf 12 -vpre medium -an -r 25 -s hd1080 timelapse.mp4 # video convert
ffmpeg -i %04d.jpg -vcodec libx264 -bf 0 -crf 12 -vpre medium -an -r 25 -s hd1080 -vf "transpose=2" timelapse.mp4 # video convert rotate
fgit gc -- ~/*/.git/.. ~/.*/.git/.. ~/dev/*/.git/.. /media/*/*/.git/.. /run/media/"$USER"/*/*/.git/..
fgit pull -- ~/*/.git/.. ~/dev/*/.git/.. "/run/media/${USER}"/*/*/.git/..
fgit status -- ~/*/.git/.. ~/dev/*/.git/.. "/run/media/${USER}"/*/*/.git/..
fgit --help
fg # foreground job
fg && command # append command continue
file README.markdown
find -L . -type l # broken symlinks
find -version
find . -empty
find . -empty -delete # remove files
find . -exec printf '%s\0' {} + | while read -r -d ''; do printf %q "$REPLY"; printf '\n'; done
find . -group 1000 -exec chgrp "$(id --group)" {} + # update files permissions
find . -mindepth 1 -exec printf x \; | wc -c # count files posix safe
find . -mindepth 1 -exec printf '%s\0' {} + | shuf --head-count 10 --zero-terminated # random shuffle files
find . -path ./.git -prune -o \( -type f -exec rg --files-with-matches $'\t' {} + \) # exclude vcs directories tab files
find . -regex '.*\(\.orig$\|\(_\(BACKUP\|BASE\|LOCAL\|REMOTE\)_\).*\)' -delete # remove git rebase temp files
find . -type f -executable # files
find . -type f -name '*.odg' -execdir libreoffice --headless --convert-to fodg {} + # convert binary xml
find . -type f -name '*.ods' -execdir libreoffice --headless --convert-to fods {} + # convert binary xml
find . -type f -name '*.odt' -execdir libreoffice --headless --convert-to fodt {} + # convert binary xml
find . -type f -name '*.*' | sed -e 's/.*\.//' | sort | uniq --count | sort --general-numeric-sort # file extensions count
find /proc -regex '/proc/[0-9].*' -prune -o -print # not process number
firefox -no-remote -P secondary &
firefox -profilemanager & # config
firefox -safe-mode &
firefox /tmp/xterm-screenshot.*.html
firefox /usr/share/doc/c-cpp-reference/html/CPLUSPLUS/cref.html # help c++ cpp dev
firefox /usr/share/doc/c-cpp-reference/html/C/cref.html # help c dev
firefox /usr/share/doc/debian-policy/policy.html/index.html # packaging linux dev
firefox /usr/share/doc/developers-reference/index.html # packaging linux dev
firefox /usr/share/doc/git-doc/index.html # dev help
firefox /usr/share/doc/ipython/html/index.html # dev help
firefox /usr/share/doc/maint-guide/html/index.en.html # packaging linux dev help
firefox /usr/share/doc/nethack-spoilers/gazetteer/index.html # game
firefox /usr/share/doc/ntp-doc/html/ntpq.html # help
firefox /usr/share/doc/python-doc/html/index.html # dev help
firefox /usr/share/doc/python-matplotlib-doc/html/index.html # dev help
firefox /usr/share/doc/python/python-policy.html/index.html # debian dev help
firefox /usr/share/doc/w3-recs/html/www.w3.org/TR/2003/REC-SVG11-20030114/index.html # help reference svg 2d graphics
fold --width 1 <<< foo # split characters lines
fortune
for path in ./*.jpg; do mogrify -resize '1920x1080>' "$path"; done # resize 1080p height
for path in ./*.jpg; do mv --verbose "$path" "$(printf "%04d" "$index").jpg"; let index+=1; done; unset index
for path in ./*.mp4; do ffmpeg -ss 1 -i "$path" -qscale:v 4 -frames:v 1 -huffman optimal "${path%.mp4}.jpg"; done # convert video extract frame image podcast
for path in ./*.sass; do sass-convert "$path" "${path%.*}.scss"; done
for path in ./*.zip; do unzip "$file"; done # all
for path in ./*/.git/..; do cd "$path"; git -C "$(git rev-parse --show-toplevel)" checkout-index --all --prefix="../$(basename "$(git rev-parse --show-toplevel)")-copy/"; cd -; done # backup repos
for path in /sys/class/net/*/address; do printf '%s\t%s\n' "$(cut --delimiter=/ --fields=5 <<< "$path")" "$(cat "$path")" ; done # list network interface mac address
for vcard in ~/contacts/*.vcf; do python2 ~/dev/msort/msort.py --bp 'BEGIN:VCARD.*?END:VCARD\r\n\r\n' --sp '^N:(.*)$' < "$vcard" > "$vcard"2; mv "$vcard"2 "$vcard"; done
free --human # memory
fromdos -- file # convert newline
fswebcam --loop 5 --resolution 640x480 webcam.jpeg # webcam capture
full_name="$(getent passwd "$USER" | cut -d ':' -f 5)" && gphoto2 --set-config /main/settings/artist="$full_name" --set-config /main/settings/copyright="Copyright $full_name" --set-config /main/settings/ownername="$full_name" # set camera config
fuseiso -p file.bin "/run/media/${USER}/mountpoint" # mount
fusermount -uz "/run/media/${USER}/mountpoint" # lazy unmount
gcc -Wall -o a.out foo.c # compile
gcc --version
gdb program # debug
gem install bundler
gem list --local
gem server
gem uninstall foo # remove
getconf ARG_MAX # arguments
getconf -a # system configuration
getent ahosts example.org # dns hosts internet ipv4 decimal
getent aliases "$USER"
getent hosts example.org # dns hosts internet ipv6 hex
getent passwd "$USER" | cut -d ':' -f 5 # user full name
gethostip -d example.org # dns hosts internet ipv4 decimal
get_iplayer --help # bbc video audio download uk
get_iplayer --type=liveradio,tv,radio,livetv --modes=best # bbc video audio download uk
gitk --all . & # gui
gitstats ~/dev/tilde ~/gitstats && x-www-browser ~/gitstats/index.html # statistics history repo
git
git add LICENSE
git add Makefile
git add README.markdown
git add tools.mk
git add --interactive
git add --patch
git add .gitignore
git add .
git bisect bad
git bisect good
git bisect reset
git bisect run ./bisect.sh
git bisect start HEAD HEAD~10
git blame 1234abcd filename # revision
git blame filename
git branch
git branch --all # list
git branch --delete topic # local
git branch --remotes
git branch --set-upstream-to=origin/master master # track
git branch --track topic master
git checkout master # branch change
git checkout -b topic remotes/origin/topic # branch change create
git checkout . # revert
git cherry-pick HEAD@{5}
git cherry-pick master:HEAD
git clean --dry-run -dx # directories .gitignore
git clean --dry-run -d # directories
git clone git://libdivecomputer.git.sourceforge.net/gitroot/libdivecomputer/libdivecomputer
git clone --recurse-submodules https://github.com/l0b0/cronlist.deb ~/dev/cronlist-0.1 && cd ~/dev/cronlist-0.1 && git remote add upstream git://github.com/l0b0/cronlist.git && git fetch upstream && git branch upstream && wget --output-document ~/dev/cronlist_0.1.orig.tar.gz https://github.com/l0b0/cronlist/tarball/v0.1 && git-import-orig --pristine-tar ~/dev/cronlist_0.1.orig.tar.gz
git clone --recurse-submodules https://github.com/l0b0/mkgithub.git
git commit
git commit --all --message "Example"
git commit --amend
git config branch.master.rebase true
git config diff.minimal
git config diff.minimal false
git config diff.minimal invalid
git config diff.minimal true
git config --global github.user l0b0
git config --global mergetool.prompt false
git config --list
git difftool old new # gui
git diff
git diff HEAD^ -- README.markdown # last commit
git diff master origin/master
git diff origin/master..HEAD # remote
git diff 'HEAD@{2013.04.30 08:00}' # date
git diff --cached # stage
git diff --color-words
git diff --exit-code # check
git diff --ignore-all-space
git diff --ignore-all-space --no-color | git apply --cached
git diff --ignore-space-change
git diff --raw
git diff --staged
git diff --staged --ignore-space-at-eol
git diff --staged --stat
git diff --word-diff
git diff | diff-ignore-moved-lines
git fetch
git fetch && git merge FETCH_HEAD # pull
git format-patch --find-renames HEAD^
git gc # garbage collect
git grep -I --name-only --null -e '' | xargs --null sed --in-place 's/[ \t]\+\(\r\?\)$/\1/;$a\' -- # git whitespace eol eof
git gui &
git help add
git help bisect
git help blame
git help branch
git help checkout
git help checkout-index
git help cherry-pick
git help clean
git help clone
git help commit
git help config
git help difftool
git help diff
git help fetch
git help format-patch
git help gc # garbage collection
git help grep
git help gui
git help help
git help ignore
git help init
git help instaweb
git help log
git help ls-files
git help ls-tree
git help mergetool
git help merge
git help mv
git help pull
git help push
git help rebase
git help reflog
git help remote
git help request-pull
git help reset
git help revert
git help show
git help stash
git help status
git help submodule
git help tag
git init
git instaweb start
git instaweb stop
git log
git log Makefile
git log origin/master..HEAD # remote
git log --after '2012-01-20 17:06' --before '2012-04-03 16:15' # date range
git log --all --decorate --graph # branch
git log --oneline --decorate
git log --patch-with-stat
git log --stat
git ls-files '*.py' # list files
git ls-tree --long HEAD ./* | awk '{print $4 " " $5}' # file size commit
git mergetool
git merge origin/master
git merge topic # local branch
git merge --abort # cancel revert
git mv README{,.markdown}
git pull
git pull --recurse-submodules=yes --update-head-ok origin master # follow initial fetch
git push
git push origin COMMIT:BRANCH # push commit
git push origin :BRANCH # delete remote branch
git push origin :refs/tags/name # delete remote
git push --set-upstream origin BRANCH # push new branch
git push --tags
git rebase master
git rebase origin/master # avoid empty merge commit
git rebase --abort
git rebase --continue
git rebase --interactive origin/master # change local commits
git reflog
git reflog show --patch-with-stat
git remote add -f origin ssh://[email protected]/home/user/repo
git remote --verbose # list
git reset v0.1
git reset --soft HEAD~1 # commit undo
git revert 123abc # commit undo
git show commit:./path > path.old
git stash drop stash@{0} # delete
git stash list --date=local
git stash list --patch # diff
git stash pop
git stash pop stash@{1}
git stash save "message"
git stash save --keep-index "message"
git stash save --patch "message" # diff create
git stash show
git stash show --patch stash@{1} # diff
git stash show --patch # diff
git stash && git merge origin/master && git stash pop
git stash && git pull && git stash pop
git stash && git rebase --interactive HEAD~20
git stash --keep-index # stage
git stash --patch # diff create
git status
git submodule add --force git://github.com/l0b0/make-includes.git
git submodule add --force git://github.com/l0b0/shell-includes.git
git submodule update --init
git subtree add --prefix=example [email protected]:l0b0/example.git master # merge repository history
git tag v0.1
git tag --delete name # local
git -C "$(git rev-parse --show-toplevel)" checkout-index --all --prefix="../$(basename "$(git rev-parse --show-toplevel)")-copy/" # copy repository file
git --git-dir=../other/.git format-patch --keep-subject -1 --stdout HEAD | git am --keep --3way # cherry-pick commit head repo
git --version
glabels & # graphics
glc-capture --out recording.glc minecraft
glc-play recording.glc
glc-play recording.glc -a 1 -o recording.wav # audio
glc-play recording.glc -y 1 -o - | mencoder -demuxer y4m - -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=3000 -audiofile recording.wav -oac mp3lame -o recording.avi # video encoding mp4 mpeg4
glxgears # 3d graphics benchmark
glxinfo
gpg --allow-secret-key-import --import ~/secring.gpg
gpg --armor --export 92126B54 # print public key text
gpg --decrypt encrypted.asc
gpg --decrypt | gpg --import # import key signature
gpg --delete-keys 44E2703A
gpg --edit-key 4DF0089E
gpg --export --armor --output 92126B54.public.gpg.key 92126B54 # export public key file
gpg --full-gen-key # create key
gpg --gen-revoke --output 4DF0089E.rev 4DF0089E # generate revoke key certificate file
gpg --import ~/pubring.gpg
gpg --keyserver keys.gnupg.net --receive-keys 55D0C732 # import pgp signature
gpg --list-public-keys --with-fingerprint # print public keys
gpg --list-secret-keys --with-fingerprint # print private keys
gpg --list-sigs 92126B54 # key signature
gpg --send-key 92126B54 # upload
gpg --verify ./*.sig # pgp signature
gphoto2 --auto-detect # camera hardware
gphoto2 --capture-image-and-download --frames 100 --interval 1 # time series capture usb camera
gphoto2 --get-config /main/settings/artist # artist
gphoto2 --get-config /main/settings/copyright # copyright
gphoto2 --get-config /main/settings/ownername # camera owner
gphoto2 --get-config=/main/status/batterylevel # battery camera
gphoto2 --get-config=/main/status/lensname # lens camera
gphoto2 --list-config | while read line; do echo $line; gphoto2 --get-config=$line; done # all camera config
gphoto2 --list-files # camera list photo
gphoto2 --port usb: --abilities # camera list abilities usb
gphoto2 --set-config /main/settings/datetime=now # camera set time date
gphoto2 --summary # camera hardware
gradle tasks # list command
grive # upload download sync files google drive
grive --auth # authenticate google drive
groups
groups nobody
groups "$USER"
gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=unencrypted.pdf -c .setpdfwrite -f encrypted.pdf # pdf remove password
gunzip example.gz
gzip example.txt # compress
hash # list program recent
heimdall detect # list android
heimdall download-pit --no-reboot --output my.pit && heimdall flash --pit my.pit --ABOOT aboot.mbn --BOOT boot.img --CACHE cache.img.ext4 --HIDDEN hidden.img.ext4 --QHEE hyp.mbn --MODEM modem.bin --APNHLOS NON-HLOS.bin --RECOVERY recovery.img --RPM rpm.mbn --SBL1 sbl1.mbn --SYSTEM system.img.ext4 --QSEE tz.mbn --verbose --no-reboot --resume # android flash mobile
help alias
help bg
help bind
help builtin
help command
help continue
help declare
help disown
help echo
help enable
help exec
help exit
help fc
help fg
help help
help history
help jobs
help kill
help local
help printf
help shift
help shopt
help test
help trap # signal
help typeset
help ulimit
help umask
help unset
help until
help wait
help # list all
help . # source
help [r]ead # read
help [s]et # set
help [t]ime # time
help [t]ype
hiera --config ~/dev/root/hieradata/hiera.yaml fonts::packages ::osfamily=Archlinux
hiera --help
history | less
hostid # host id hex
hostname # internet network
hostname --ip-address # internet network address dns
hostname --short # internet network
host example.org # dns lookup internet network ipv4 ipv6
hp-setup # printer
hp-wificonfig # printer
htop # monitor processes system
hugin & # panorama 2d photo stitch
iconv --from-code=utf-8 --to-code=iso-8859-1 utf8.txt > latin1.txt # convert encoding
idea & # intellij idea ide
id "$USER"
id # group user
id --group
id --user
if [[ -r /proc/sys/kernel/ns_last_pid ]]; then while true; do while read; do if [[ "$REPLY" != "$old" ]]; then printf '%(%s)T %d\n' -1 "$REPLY"; old="$REPLY"; fi; done < /proc/sys/kernel/ns_last_pid; read -t 1 || true; done; fi # processes pids log
imapfilter
img2scad < test.png # openscad convert image
indentect --help
indentect --verbose < "$(which indentect)"
indentect < "$(which indentect)"
indent ./*.c
infocmp -1 # list terminal
info --raw-escapes --subnodes autoconf | less --raw-control-chars # help
info --raw-escapes --subnodes automake | less --raw-control-chars # help
info --raw-escapes --subnodes date | less --raw-control-chars # help
info --raw-escapes --subnodes dd | less --raw-control-chars # help
info --raw-escapes --subnodes find | less --raw-control-chars # help
info --raw-escapes --subnodes ls | less --raw-control-chars # help
info --raw-escapes --subnodes mktemp | less --raw-control-chars # help examples temporary files
info --raw-escapes --subnodes sed | less --raw-control-chars # help
inkscape & # editor svg
iostat
ipcalc 0.0.0.0/0 # network
ipcalc 192.168.0.1/24 # network
ipython
ip addr show dev eth0 # ipv4 ipv6 device address
ip addr show # ipv4 ipv6 network address
ip link show down # network
ip link show up # network
ip route show dev eth0 # network
ip -oneline -family inet addr show dev eth0 # ipv4 address
iwconfig # wireless network configuration
iwlist scanning
java -Xmx4096M -Xms512M -jar ~/.minecraft/launcher.jar
java -jar ~/schemaSpy.jar -dp /usr/share/java/mysql.jar -hq -t mysql -host localhost:3306 -db database -u user -p password -o ~/db && x-www-browser file://"$HOME"/db/index.html # mysql db visualization
java -jar ~/schemaSpy.jar -dp /usr/share/java/postgresql.jar -hq -t pgsql -host localhost:5432 -db database -s public -u user -p password -o ~/db && x-www-browser file://"$HOME"/db/index.html # postgresql db visualization
jhead -da2010:11:12/13:14:15-2005:01:01 ./*.jpg # adjust date time image
jobs -l # list all background
journalctl --boot --catalog --output=short-iso
journalctl --catalog --follow
journalctl --catalog --lines=10
journalctl --catalog --since=today --output=short-iso SYSLOG_IDENTIFIER="xprofile-${USER}" # log user x profile
journalctl --catalog --since=today --output=short-iso # systemd service log
journalctl --catalog --since=today --unit=shadow.service
jq . < *.json # json pretty-print
json_xs -t null < example.json # verify json format
json_xs < example.json # prettify json
kdiff3 --output OUTFILE OURS THEIRS # merge
keybase help
keybase login
keybase prove twitter
killall process
kill -0 "$!" # check last job background process pid
kill -18 "$!" # resume last job background process pid
kill -20 "$!" # suspend last job background process pid
kill -INT $$ # signal
kill -l # list signals
komodo &
ktrash --empty # kde trash empty delete
kvm -boot d -m 512 -cdrom archlinux-*.iso # vm
kvm -hda /tmp/my.img -cdrom boot.iso -boot d # vm
lastlog # login users
last | less # list all user login history
la ~
la
ldconfig --print-cache # list all libraries
ldd "$(which bash)"
less Makefile
less "/usr/share/X11/locale/$(rg --max-count=1 "${LANG%.*}.UTF-8\$" /usr/share/X11/locale/locale.dir | cut --delimiter=/ --fields 1)/Compose" # keyboard shortcuts
less --RAW-CONTROL-CHARS filename # color
less --raw-control-chars typescript
less /etc/issue
less /etc/passwd # password
less /proc/bus/input/devices
less /sys/class/dmi/id/product_name
less /sys/class/dmi/id/sys_vendor
less /usr/share/doc/nethack-common/Guidebook.txt.gz # help
less /var/log/Xorg.0.log
less /var/log/auth.log
less /var/log/dmesg
less /var/log/kern.log
less /var/log/messages
libreoffice &
livestreamer http://www.twitch.tv/foo best & # video web
ll
ln --symbolic -- target source
localectl list-keymaps # keyboard layout list
localectl list-x11-keymap-layouts # keyboard layout list
localectl list-x11-keymap-models # keyboard list
localectl list-x11-keymap-variants us # keyboard list
locale
locale --all-locales
locate file
lpstat -d # default printer cups
lpstat -v # list all printers cups
lsblk # list block device disk
lsblk --noheadings --output UUID /dev/mapper/vg-swap # disk uuid
lsb_release --all # linux version distro
lscpu # hardware architecture processor
lscpu | rg '^CPU op-mode' # detect cpu bit mode
lshw
lslocks # list file locks
lsmod # kernel modules
lsof # list open files
lsof +D /path # list open file directory recursive
lsof +L1 # list deleted files
lsof +c 0 | rg process-name | wc --lines # count files
lsof -i tcp # internet network
lsof -i :22 # internet port network
lsof -p $$ # files process
lspci # list pci hardware
lspci -v -s 00:1b.0 # pci device details
lspci | rg --ignore-case audio # pci device
lsusb # list usb hardware
lsusb | rg --ignore-case cam
ls -lt /var/log/ # sort time list
ls -l --all # list
ls -l --block-size 1 # list files size bytes
ls -l --directory ./*/ # list directories
ls -l --reverse # list
ls --directory /proc/[^0-9]* # metadata
lyx file.lyx
l ~
l
m4 --version # compile dev
makepkg --printsrcinfo > .SRCINFO # package generate metadata
makepkg --syncdeps --force # package build rebuild
makepkg --syncdeps --install # package build tarball install
make clean # dev
make install # dev
make test # dev
make variables # dev
make variable-SHELL # dev
make # compile dev
make --silent python-pep8 | cut --delimiter=: --fields=4- | rg --invert-match '^$' | sort | uniq --count | sort --numeric-sort
man 1p mv # posix help
man 1p sort # posix help
man 1p xargs # posix help
man 2 open # help
man 3 exit # help
man 3 printf # help format %d %f %s
man 5 crontab # help
man 5 passwd # help password
man 5 sshd_config # help
man 5 sudoers # help
man 7z # help
man 7 glob # help
man Xorg # help
man abcde # help
man acpid # help
man acpi_listen # help
man ag # help
man align_image_stack # help
man alsamixer # help
man amixer # help
man aplay # help
man appres # help
man apropos # help
man arandr # help
man arch # help
man arecord # help
man arm # help
man arp # help
man ascii # help
man ash # help
man asn1parse # help
man avahi-browse # help
man avahi-daemon # help
man avconv # help
man awesome # help
man awk # help
man badblocks # help
man basename # help
man bashdb # help
man bash # help
man bc # help
man blkid # help
man borg # help
man borg-create # help
man borg-delete # help
man borg-init # help
man bsdtar # help
man builtins # help bash
man bunzip2 # help
man bzip2 # help
man cal # help
man charsets # help
man checkbashisms # help
man chfn # help
man chgrp # help
man chmod # help
man chown # help
man chroot # help
man clamd # help
man clamscan # help
man cloc # help
man cmp # help
man comm # help
man convert # help
man coredumpctl # help
man cpio # help
man cppcheck # help
man cp # help
man createdb # help postgresql
man createuser # help
man crond # help
man crontab # help
man cryptsetup # help
man csplit # help
man curl # help
man cut # help
man darktable # help
man debhelper # help
man delgroup # help
man deluge # help
man deluser # help
man df # help
man dhclient # help
man dh_make # help
man diffoscope # help
man diff # help
man digikam # help
man dig # help
man dirname # help
man dmesg # help
man dmidecode # help
man dockerfile # help
man dos2unix # help
man dotty # help
man dot # help
man download-mibs # help
man dropdb # help postgresql
man dropuser # help
man dsa # help
man du # help
man efibootmgr # help
man eject # help
man ent # help
man envsubst # help
man env # help
man errno # help
man etherape # help
man exiftool # help
man exiv2 # help
man expand # help
man expect # help
man faillog # help
man fakeroot # help
man fceux # help
man fc-cache # help
man fc-list # help
man fdisk # help
man feh # help
man ffmpeg # help
man file # help
man find # help
man firefox # help
man fmt # help
man fold # help
man fortune # help
man free # help
man freshclam # help
man fsck # help
man fswebcam # help
man fuseiso # help
man fusermount # help
man gcc # help
man gdb # help
man genrsa # help
man getconf # help
man getent # help
man gethostip # help
man getopt # help
man gfortran # help
man gitk # help
man gitstats # help
man git # help
man glabels # help
man gnome-keyring-daemon # help
man gpasswd # help
man gpg # help
man gphoto2 # help
man graphviz # help
man grive # help
man groupadd # help
man groupdel # help
man groups # help
man grpck # help
man grub-mkconfig # help
man gsmartcontrol # help
man gs # help
man gunzip # help
man gvfs # help
man hash # help
man head # help
man hexdump # help
man hier # help
man history # help
man hostid # help
man hostname # help
man hosts # help
man host # help
man htop # help
man hugin # help
man hunspell # help
man id # help
man iftop # help
man imake # help
man imapfilter # help
man imapfilter_config # help
man indent # help
man infocmp # help
man initdb # help postgresql server database
man inkscape # help
man inotifywait # help
man inotify # help
man install # help
man interfaces # help
man ionice # help
man iostat # help
man iotop # help
man ipcalc # help
man iptables # help
man ip # help
man iwconfig # help
man iwlist # help
man java # help
man jhead # help
man join # help
man journalctl # help
man json_pp # help
man json_xs # help
man kdesu # help
man keytool # help
man kill # help
man kismet # help
man kvm # help
man lastlog # help
man last # help
man ldconfig # help
man ldd # help
man ld # help
man less # help
man libreoffice # help
man lighttpd # help
man line # help
man lintian # help
man livestreamer # help
man ln # help
man localectl # help
man locale # help
man locate # help
man logger # help
man lpadmin # help
man lpstat # help
man lsblk # help
man lsb_release # help
man lscpu # help
man lslocks # help
man lsmod # help
man lsof # help
man lspci # help
man lsusb # help
man lynx # help
man makepkg # help
man make # help
man man # help
man mcomix # help
man md5sum # help
man mencoder # help
man mkdir # help
man mkfifo # help
man mkfs.ext4 # help
man mkfs.msdos # help
man mktemp # help
man modinfo # help
man modprobe # help
man mogrify # help
man mount # help
man mp3fs # help
man mutt # help
man mv # help
man mysql # help
man namcap # help
man nautilus # help
man ncal # help
man ncdu # help
man nc # help
man netctl # help
man netctl.profile # help
man nethogs # help
man netstat # help
man newgrp # help
man nfs # help
man nice # help
man nl # help
man nmap # help
man nm # help
man node # help
man notify-send # help
man nproc # help
man nslookup # help
man ntpd # help
man ntpq # help
man objdump # help
man od # help
man openscad # help
man openssl # help