Hi I am new to programming, so I wanna know how I can save the progress I make after, processing a file in the Linux terminal. Note that it is a vcf file which I am editing with vcftools and GATK.
And after I save the file how can I retrieve the progress I made to continue where I left without having to redo everything?
Dear hdtms, the best way to save your work is by saving a new file after each edit that you make.
VCFtools has built-in paramaters that allow you to output a new file after each command - take a look at the -recode and -out command-line parameters.
If you are using GATK to call variants (or do something else) and it is taking a very long time, you should consider devoting more resources to your process so that it finishes quicker, and also check to ensure that you actually have enough memory. Some of these programs fail to manage memory sufficiently and end up in a 'never ending' process once memory fills up. Otherwise, if you already have sufficient resources and literally just want to ensure that your work is saved, the GATK also provides command-line parameters for saving output.
Finally, if you use a linux virtual machine, it (the virtual machine) may be able to take a snapshot of your instance and then return to it at any point.
This list of ideas is not exhaustive and others may suggest more.
Edit: there is a thread here that also recommends the save and VM options that I mentioned, but also has a few others: https://unix.stackexchange.com/questions/43854/save-entire-process-for-continuation-after-reboot