2021-01-13 17:30:32 +01:00
|
|
|
title = Making backups
|
2021-01-11 19:16:35 +01:00
|
|
|
cards =
|
|
|
|
|
|
|
|
[description]
|
|
|
|
|
|
|
|
One month later, you're working on an essay about cats.
|
2021-01-13 17:30:32 +01:00
|
|
|
|
2021-01-11 19:16:35 +01:00
|
|
|
You've started making backup copies of your essay regularly - you can look at them by clicking on them!
|
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
You think that you're almost done - your current version, just needs one more line!
|
2021-01-11 19:16:35 +01:00
|
|
|
|
|
|
|
[congrats]
|
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
Okay, this kind of works.
|
|
|
|
|
|
|
|
But you're a bit worried that two weeks from now, you'll have hundreds of copies of your essay, and it will be hard to keep track of all of them.
|
|
|
|
|
|
|
|
And especially when working with other people, sending copies back and forth doesn't seem ideal.
|
2021-01-11 19:16:35 +01:00
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
You wonder what would be a better way to do this.
|
2021-01-11 19:16:35 +01:00
|
|
|
|
|
|
|
[setup]
|
|
|
|
|
|
|
|
rm -rf .git
|
|
|
|
|
|
|
|
echo "~ Why cats are the best pets ~
|
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
(I still need to write this.)" >> essay.txt
|
2021-01-11 19:16:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
echo "~ Why cats are the best pets ~
|
|
|
|
|
|
|
|
- They live longer than goldfish." >> essay2.txt
|
|
|
|
|
|
|
|
|
|
|
|
echo "~ Why cats are the best pets ~
|
|
|
|
|
|
|
|
- They live longer than goldfish.
|
2021-01-13 17:30:32 +01:00
|
|
|
- Their little paws are super cute." >> essay2_final.txt
|
2021-01-11 19:16:35 +01:00
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
cp essay2_final.txt essay2_really_final.txt
|
2021-01-11 19:16:35 +01:00
|
|
|
|
|
|
|
[win]
|
|
|
|
|
2021-01-13 17:30:32 +01:00
|
|
|
# Add another line to essay2_really_final.txt!
|
|
|
|
test "$(cat essay2_really_final.txt | wc -l )" -ge 5
|