As previously announced, I'll soon decommission the old logger at logs.ossasepia.com and redirect that url to the saner, persistent logs. Since I don't want to break anyone's links though, I took the time to extract the full mapping of urls from old to new so that anyone interested can simply run a replace on any text containing the old links. If you get stuck with this and ask in the comments below, I can try to help if it's clear enough what the problem is but do note that *not everything can be fixed* nor do I promise to be able to help everyone.
For completeness and future reference, here are the steps I followed to extract this mapping and then to update the links on my own blog for #ossasepia and #eulora chans:
- Dumped numbers and dates for all loglines from old bot's database into file1
- Dumped publication date, log date and database title for all log articles from the blog's database into file2
- Processed file2 above to obtain the full url matched with corresponding log date for all log articles
- Merged file1 and file2 on log date1 so that each logline is matched with the full url of the article that contains it
- Using the output of the above, I ran directly a script that generates the needed sql query2 to replace the old link with the new but for your convenience I also dumped to a separate file the exact mapping old link next to new link for all lines, so that all you have to do is find the old link in there and take from the same line its corresponding new link: oldnewloglinks.tar.gz.
The above archive covers log lines up to the end of April 2020 (as the new logs were already up by then) and includes both #ossasepia and #eulora logs as those are published as articles on my blog. For logs of other chans (e.g. #trilema), the mapping rules might be different. For loglines from May 2020, there's only one article for each month (see the logs category), so you can easily get the appropriate new link for those too, if you need them (the line number is used as anchor on purpose, so that there is direct correspondence there, to make this sort of update easier). In principle, to the extent that other loggers are/were in sync with mine - and this is something you can spend way too much time on, to check! - you can use the above to update those links too - simply replace the logs.ossasepia.com with the other logger's url and find the correct mapping anyway, though you'll have a hell of a time to find and then correct errors caused by the smallest out of sync.
Just in case you haven't yet messed up anything important enough to have gotten already the habit of backups - do remember to do a backup of whatever it is you plan to change *before* rushing to change it!
join -1 1 -2 2 <(sort -k1 file1.txt) <(sort -k2 file2.txt) ↩
E.g. update yourblog_posts set post_content=replace(post_content, 'ossasepia.com/2020/04/30/ossasepia-logs-for-30-Apr-2020#1025541', 'ossasepia.com/2020/04/30/ossasepia-logs-for-30-Apr-2020#1025541'); ↩
Comments feed: RSS 2.0