small bioinformatics helpful codes
- find meth/ -name "201247470004_R03C01_Grn.idat" -print
- find Liver_MM/ -type d -exec chmod 775 {} ; #directories
- find Liver_MM/ -type f -exec chmod 664 {} ; #files
- setfacl -m u:username:r raw_files #set permissions for a user in group
- Command for rsync from HTC to PSC. Adding
/
at the end ofAnish_Projects
, transfers the contents under this folder, but not the folder itself. rsync -avh --progress -e "ssh -p 2222" Anish_Projects/ abc46@pghbio.bridges.psc.edu:/pghbio/dbmi/Genomics_Core/achakka/File_Transfers/HTC/ - Macbook to PSC: rsync -avh --progress -e "ssh -p 2222" T1T2T3candidatesequencelist7_12.fa abc46@pghbio.bridges.psc.edu:/pghbio/dbmi/Genomics_Core/achakka/Misc/Moore/Data
- Bridges to Bridges2 rsync -avh --progress achakka/ achakka@data.bridges2.psc.edu:/ocean/projects/bio140004p/achakka
- md5sum --quiet -c file.md5sum
- find your_folder -type f -exec md5sum ‘{}’ ; > md5sum.txt ##recursively obtain md5sum values in an entire folder
- First occurrence: ${parameter/pattern/string}
- All occurrences: ${parameter//pattern/string}
- head -2 file.maf > all.txt; tail -n +3 -q *.maf >> all.txt
- sbatch --dependency=afterok:11254323 job2.sh