Neocities.org

Mike Grindle's Webpage

mikegrindle.com

581,229 views
107 followers
2,752 updates
0 tips
>https://mikegrindle.com/posts/obtf Be considerate of your disk's health. Assuming that you're not booting from RAM (if you are, good on you), every time you save your big text file, all of its contents are re-written to disk. Having multiple separate files circumvents this issue.
1 like
kaa 7 months ago

You may have your big file split into separate files every now and again automatically. Guessing that you continue your file at the top, you may have a shell script such as: "limit=9999; lines=$(wc -l mybigfile); if [ $lines -gt $limit ]; then head -$(($lines / 2)) mybigfile > 2024-04-23.chunk; tail -$(($lines / 2)) > /tmp/a; mv /tmp/a mybigfile; fi"

1 like
kaa 7 months ago

If you need to view all of the text at once, try "cat * | less".

1 like
mikegrindle 7 months ago

I hear what you're saying, but in practical terms my "big" text file isn't nearly big enough for that to be an issue (it's still under a MB). Thanks to wear-leveling, you would have to seriously stress-test a drive for that to become an issue, though I always back-up and would split up a file if it ever got really big.

3 likes
mikegrindle 7 months ago

On the anecdotal side, I've known people who have used larger OBTFs for years with zero issue. Plenty of notetaking software programs like JRNL use single text files too w/o problems, so I'm not too worried tbh. Thanks anyway, though.

2 likes

Website Stats

Last updated 2 days ago
CreatedNov 3, 2022
Site Traffic Stats

Tags

writing blogging technology links essays