Created
March 14, 2015 20:24
-
-
Save suryasaha/f847ac6b5bb693004c47 to your computer and use it in GitHub Desktop.
WICC Workshop March 14 2015
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Github repo for Shell | |
https://github.com/suryasaha/shell-novice | |
Github repo web page | |
http://suryasaha.github.io/shell-novice/ | |
Clone the repo | |
git clone https://github.com/suryasaha/shell-novice.git | |
OR | |
wget ftp://ftp.solgenomics.net/bioinfo_class/other/2015/nelle.zip | |
unzip nelle.zip | |
File for Perl exercises | |
ftp://ftp.solgenomics.net/bioinfo_class/other/2014/perl_class_files.zip | |
LECTURE NOTES | |
Shell Commands | |
whoami - Tells you what user you are logged in as | |
ls - tells you what's in the current folder | |
ls -l - tells you what's in the current folder (with more information) | |
ls directory - tells you what's in the given folder | |
unzip file.zip - Unzips a file | |
command1 | less - Shows you the output of command1 one page at a time. | |
touch filename - Creates the blank file filename | |
echo "text" > filename - Creates the file filename with the content text | |
cat - Displays the contents of a file | |
nano - A text editor. | |
nano filename - Edit the file with nano. | |
cd - Change the directory. | |
../ - The parent directory of the current directory. | |
mv oldpath newpath - Moving/renaming a file | |
wc - Count words/lines/characters in a file | |
wc -c - Count characters | |
wc -l - Count lines | |
sort - Sort its input by the first "column" | |
pico - Another text editor | |
wget - Download a file | |
Piping | |
command1 | command2 | |
Takes the output of command1 and gives it as the input to command2. | |
Wildcard | |
Used in place of filenames. | |
* - All files in the current directory (e.g. wc -l *) | |
Organization of a UNIX System | |
/ - The "root" directory (like C:\ on Windows) | |
Perl | |
- An interpreted language | |
Hashes: | |
- Like Python's dictionary | |
Strict mode: | |
use strict; | |
use warnings; | |
Makes Perl be more strict about interpreting your code. | |
Testing | |
Static analysis tools | |
- Catches bugs that the compiler cannot catch | |
- C++ CppCheck, clang-analyze | |
Dynamic analysis tools | |
- Often slow but can catch bugs compiler and static analysis can miss | |
- Many good tools ( valgrind for c/c++, | |
- Sanitizers (AddressSanitizer, ThreadSanitizer) | |
Linters/Formatters for consistent formatting and layout | |
- Perl (Perl Tidy, Perl Critic) | |
- C(clang-format, clang-tidy) | |
Documentation generators | |
- JavaDoc, DoxyGen | |
Your own tests | |
- Google's include-what-you-need | |
Property tests | |
- Sample space of test inputs is generated based upon property | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment