Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Command line Tips you (might) don't know

Command line Tips you (might) don't know

975ff6c8166f6f32889f004a904ffa39?s=128

Oursky Limited

March 24, 2014
Tweet

Transcript

  1. 5 Command Line Tips you (might) don’t know Ben Cheng,

    Oursky Internal Presentation
  2. 1. bashstrap https://github.com/barryclark/bashstrap

  3. 2. set editing-mode vi ~/.inputrc

  4. Demo http://www.catonmat.net/download/bash-vi-editing- mode-cheat-sheet.pdf

  5. 3. byobu

  6. 4. pushd / popd

  7. 5. ctrl-r

  8. 5.5 long command #hash

  9. 6. ssh config

  10. Host w User chpapa Hostname hostname.com ServerAliveInterval 30 ServerAliveCountMax 2

    ControlPath ~/.ssh/master-%r@%h:%p ControlMaster auto ControlPersist 4h GSSAPIAuthentication no
  11. 7. F*ck GFW ssh -c arcfour -D 8080 server.com

  12. 8. mkdir -p /what/the/ hell

  13. 9. open .

  14. 10. pbcopy / pbpaste

  15. 11. sudo !!