BASH   42
scp rp
Guest on 4th May 2022 07:54:58 AM


  1.  
  2.  
  3. ===== scp =====
  4. %scp -rp *.pro u0140878@meteo04.ch/common/home/u0140878/
  5.  
  6. %lpstat -t       --- show prints
  7.  
  8. ===== vi =====
  9. :$ --- last line
  10. :1 --- to line 1
  11. :n --- to line n
  12. :$= --- show the number of the last line
  13. :.= --- show the number of the current line
  14.  
  15. D --- delete to the end of line
  16. dd --- delete line
  17. C --- change to the end of line
  18. $ --- to the end of line
  19. ^ --- to the head of the line
  20. w --- to the next word
  21. e --- to the end of the word
  22.  
  23.  
  24. u --- undo
  25. / --- search forward
  26. ? --- search backward
  27.  
  28. p --- paste to the next line
  29. P --- paste to the ahead
  30.  
  31. H --- top of the screen
  32. M --- middle of the screen
  33. L --- last line of the screen
  34. Ln --- last line but n
  35.  
  36.  
  37. ===== zip =====
  38. %unzip *.zip
  39. %unzip \*.zip
  40. %unzip "*.zip"
  41.  
  42. for f in *.zip;
  43.   do unzip "$f";
  44. done
  45.  
  46. ===============================
  47.  
  48.     *  man (cd, ftp, ssh, or any command for more info. "man" stands for manual)
  49.     * scp <filename> <userid>@stats.chpc<filename>
  50.     * ssh stats.chpc
  51.     * ls (see man for ls switch -als also; pipe to more by typing ls -als | more (press space bar to page down or down arrow key)
  52.     * setenv DISPLAY hostname:0.0 (for csh/tcsh)
  53.     * xterm (command shell supports tcsh)
  54.     * c++ (c++ compiler - found in /usr/local/bin along with all the other compilers)
  55.     * gcc (c compiler)
  56.     * pwd (current directory path)
  57.     * cd ("cd /" moves to root directory; "cd .." moves to previous directory, "cd" moves to your home directory, "cd /directory" moves you to /directory)
  58.     * mkdir (creates directory)
  59.     * rm (removes files and directories - man rm for info on switch -rf)
  60.     * cp (copies files - cp file1 file2)
  61.     * more filename (displays text or contents of the file. See man for cat also.)
  62.     * emacs filename (text editor for files. xemacs is also available. See setenv below.)
  63.     * mv (moves files - mv file1 file2)
  64.     * ps (lists processes - try switch -aef.)
  65.     * .cshrc (file found in user home directory; editable for adding paths, etc.)
  66.     * echo $path (shows current paths in .cshrc file)
  67.     * chmod (changes file permissions)
  68.     * ln -s /directorystructure shortcut-name (creates a shortcut to a directory from your home directory)
  69.     * scp filename username@yourcomputer.where-ever.com:/directorystructure/file (copies files to stats in a secure environment)
  70.  
  71. ===== perl =====
  72.  
  73. %perl aaa.pl                       - run perl
  74. %perl aaa.pl -f inputfilename      - run perl, read file "inputfilename"
  75. %perl -d aaa.pl                    - debug
  76. %perl -w aaa.pl                    - run with warnning

Raw Paste

Login or Register to edit or fork this paste. It's free.