Files - aechchiki/SIB_LongReadsWorkshop_Zurich18 GitHub Wiki
File organization
Section: Introduction [2/3].
Organization is important to avoid getting lost in your data.
Subfolders
For this tutorial, we suggest you to use a nested organization (e.g. considering data/script/analysis type). A possibility can be:
aechchik@danio:~/Downloads/lr_zh18$ find . -type d -links 2
./data/rna/minion/1_raw/
./data/rna/minion/2_extraction/
./data/rna/minion/3_quality/
./data/rna/minion/4_transcriptome/
(...)
./reference/
./scripts/
To save some typing, you can assign these directories to bash variables, using full-path. For example:
SCRIPTS="/Users/aechchik/Downloads/lr_zh18/scripts/"
# make sure you include the last "/" for folders
Doing so, you can:
- simply move to it from anywhere
- example:
cd $SCRIPTS
- example:
- create new files in it from anywhere
- example:
vim $SCRIPTS"test.sh"
- this will basically add string "test.sh" to string stored in var
$SCRIPTS
, thus creating the corresponding filename
- this will basically add string "test.sh" to string stored in var
- example:
Scripts
As previously mentioned, you can use a text editor to keep track of your commands. This text editor can be local (e.g. Atom) or on the Docker machine.
In Docker, we installed embedded editors that might be useful for you:
- vim
- in case you need it, we prepared a mini vim-refresher for our purposes
- nano
We will be using bash for script interpretation, unless otherwise mentioned. Make sure to:
- include suitable extension
- i.e.
.sh
(for shell script)
- i.e.
- specify the interpreter
- i.e. add
#!/usr/bin/env bash
to the very top of your script
- i.e. add
- make your script executable
- i.e.
chmod +x <script_name>.sh
- i.e.