How can I download multiple links in to a single file using aria2c
? This works but it will still download all the links as seperate files.
aria2c -i links.txt --o result.txt
How can I download multiple links in to a single file using aria2c
? This works but it will still download all the links as seperate files.
aria2c -i links.txt --o result.txt
You can use the following custom command:
aria2c2 links.txt results.txt
By defining this function:
function aria2c2() {
mkdir output && \
aria2c -i $1 --dir output && \
cat output/* > $2 && \
rm -r output
}
This will download the contents the links point to and combine them into one text file called "results.txt". This assumes you're working only with text.
To define the function for each new terminal, place it in your ~/.bashrc
file. Load it in the current terminal by entering source ~/.bashrc
.
This doesn't answer your question (i.e. how to do this with aria2c alone), but it's the best I've got and I don't have enough reputation to comment.