<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="/atom.xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<title>McKinley's Notes</title>
	<id>https://mckinley.cc/notes/</id>
	<link rel="self" href="https://mckinley.cc/notes/atom.xml"/>
	<link rel="alternate" href="https://mckinley.cc/notes/"/>
	<author>
		<name>McKinley</name>
		<uri>https://mckinley.cc/</uri>
	</author>
	<updated>2024-11-20T23:16:14-08:00</updated>
	<entry>
		<title>In Shocking Move, mckinley.cc Hurtles Into The 2010s With Very First CSS 3 Feature On Website &#x2013; Mobile Visitors Overjoyed</title>
		<id>tag:mckinley.cc,2023:notes:20241120-css3-announcement</id>
		<link rel="alternate" href="/notes/20241120-css3-announcement.xhtml"/>
		<published>2024-11-20T23:16:14-08:00</published>
		<updated>2024-11-20T23:16:14-08:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>Well, I finally did it.
					I hated seeing the obscenely long title of <a href="/notes/20241120-mintupdate-apt-cacher-ng.xhtml">today's note</a> crashing into the date even in relatively wide windows, so I finally fixed the longest-standing known bug on mckinley.cc.
					Unfortunately, the stylesheet is no longer valid CSS 2.1, but such is life.</p>
				<p>Flexbox, at least the dead simple subset of Flexbox that I'm using, is supported in any modern browser including Netsurf.
					Even very old browsers that don't support Flexbox should still be able to present it in a somewhat reasonable way.
					I might do some tweaking later to accomodate them, but people barely visit my site on modern browsers, let alone old ones.
					The important thing is, I don't have to see my titles crash into the date anymore, and that makes me happy.</p>
				<p>Oh yeah, this incidentally makes it better for visitors on smartphones.
					Not that I care about smartphone visitors, of course.
					I'm not going to wrap it for them, at least.
					With style.css rapidly approaching a kilobyte in size, It's bad enough I need a media query for printing.
					I'm certainly not giving smartphone visitors one because just because they insist on browsing the Web on a tiny vertical screen.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>Fix Linux Mint Update Manager Unreachable Message When Using Apt-Cacher NG</title>
		<id>tag:mckinley.cc,2023:notes:20241120-mintupdate-apt-cacher-ng</id>
		<link rel="alternate" href="/notes/20241120-mintupdate-apt-cacher-ng.xhtml"/>
		<published>2024-11-20T15:45:39-08:00</published>
		<updated>2024-11-20T15:45:39-08:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p><a href="https://www.unix-ag.uni-kl.de/~bloch/acng/">Apt-Cacher NG</a> works well on Linux Mint, but their Update Manger (mintupdate) complains that the mirror is unreachable.
					Even though it will still let you download packages through ACNG, mintupdate is <a href="https://github.com/linuxmint/mintupdate/blob/da504a6e0d5f49a41568db0053ae9143f625d306/usr/lib/linuxmint/mintUpdate/mintUpdate.py#L1978">checking the Last-Modified time</a> of <tt>&lt;mirror url&gt;/db/version</tt> against that of packages.linuxmint.com to determine the age of the mirror.
					If it can't reach that file, it assumes the entire mirror is unreachable and puts up that message.</p>
				<p>ACNG whitelists paths for proxying based on a few regular expressions.
					We can add this path to the whitelist in the config file, like so:</p>
				<pre># Fix for Linux Mint Update Manager (mintupdate) thinking the cache is unreachable because it can't reach the version file
		# https://mckinley.cc/notes/20241120-mintupdate-apt-cacher-ng.xhtml
		# https://github.com/linuxmint/mintupdate/blob/da504a6e0d5f49a41568db0053ae9143f625d306/usr/lib/linuxmint/mintUpdate/mintUpdate.py#L1978
		VFilePatternEx: ^/db/version$</pre>
			</div>
		</content>
	</entry>
	<entry>
		<title>How To Efficiently Copy Files To Multiple Destinations</title>
		<id>tag:mckinley.cc,2023:notes:20240508-copy-multiple-destinations</id>
		<link rel="alternate" href="/notes/20240508-copy-multiple-destinations.xhtml"/>
		<published>2024-05-08T12:08:50-07:00</published>
		<updated>2024-05-08T13:18:39-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>I bought two new hard drives recently and I'm currently doing a lot of data shuffling to get the drives into the configuration I want.
					I wanted to copy the files from one drive to two others so there will be an extra backup before I format the original drive.
					The set weighs about 6TiB so it had to be done as efficiently as possible.</p>
				<p>I needed something that would read the data once, and copy it to both destinations in parallel.
					Neither rsync nor cp could do what I wanted, but then I found this <a href="https://superuser.com/a/1064516">great solution</a> by Kamil Maciorowski on Stack Exchange.</p>
				<pre>tar -c /source/dirA/ /source/file1 |
	tee &gt;(cd /foo/destination3/ &amp;&amp; tar -x) &gt;(cd /bar/destination2/ &amp;&amp; tar -x) \
		&gt;(cd /foobar/destination1/ &amp;&amp; tar -x) &gt; /dev/null</pre>
				<blockquote>How does it work?
					First tar converts directories and files to a single bitstream that can be used in a pipe.
					The tee command forks that stream; every copy but one is extracted by tar in proper destination.
					The last copy moves down the pipe; it is discarded into /dev/null.
					(One may use the last copy for destination0 but the syntax would be different so I decided to keep it simple with tee only).</blockquote>
				<p>Genius!
					I wanted to see my progress, so I inserted pv in the pipeline.
					Mine ended up looking something like this.</p>
				<pre>tar -c * | pv -s "$(du -bs . | cut -f 1)" -m 300 |
	tee &gt;(cd /foobar/destination1/ &amp;&amp; tar -x) &gt;(cd /bar/destination2/ &amp;&amp; tar -x) &gt;/dev/null</pre>
				<p><tt>-S</tt> (<tt>--sparse</tt>) is very important in the <tt>tar</tt> command because it makes tar handle sparse files properly.
					On the first run, I forgot I had a few disk images as sparse files and I realized it was writing out the empty parts to the disk.</p>
				<p>pv is telling me there's about 14 hours left in this transfer.
					I better get a cup of tea.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>On Website Builders</title>
		<id>tag:mckinley.cc,2023:notes:20240125-website-builders</id>
		<link rel="alternate" href="/notes/20240125-website-builders.xhtml"/>
		<published>2024-01-25T19:24:16-08:00</published>
		<updated>2024-01-25T19:24:16-08:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p><i>Re: <a href="https://twtxt.net/conv/hav3dva">Can anyone recommend a website builder for dummies?</a><sup><a href="https://web.archive.org/web/20240126030207/https://twtxt.net/conv/hav3dva">[archived]</a></sup> by <a href="https://twtxt.net/user/prologic">@prologic@twtxt.net</a> on twtxt</i></p>
				<p>I have never seen a good website builder for dummies.
					Many of them are extremely narrow in the type of website they will make, and if they aren't they're way more frustrating to use than writing HTML/CSS.</p>
				<p>It's like those websites that will let you create your own business cards according to a template.
					They might look OK, but then you have the exact same business card as everyone else in town.
					If you want to tweak the template, the web-based tools are so bad and so frustrating you might as well learn how to use Inkscape and send the SVG to your local print shop.</p>
				<p>That said, many are "good enough" for some people even if they generate ridiculous multi-megabyte monstrosities with all kinds of external JavaScript that we technical people might hate.
					Wix is the one for which I have the most first-hand knowledge.
					It's a great example of the second type of website builder.
					You can make whatever you want, but the tools will fight you the whole way there.</p>
				<p>The owner of the website has to employ all kinds of tricks to get text to appear where he wants.
					Sometimes, edits to one part of a page can have strange, unpredictable effects on another and the only way to fix it is to roll back the entire site and try the edit again.
					The home page is currently 3.84 MB in size and 1.26 MB compressed, and that's with uBlock Origin blocking all the tracking garbage.
					I think he pays almost $20 per month for the privilege.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>Terrible Website of the Day</title>
		<id>tag:mckinley.cc,2023:notes:20240122-terrible-website</id>
		<link rel="alternate" href="/notes/20240122-terrible-website.xhtml"/>
		<published>2024-01-22T23:15:17-08:00</published>
		<updated>2024-01-25T18:57:03-08:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>Some AI company I've never heard of made a way for webmasters to opt out of Web crawlers used to train AI models.
					The idea is fine and the implementation is exactly the same as robots.txt, which is also fine.
					What is not fine, however, is the <a href="https://spawning.ai/ai-txt">Web page</a> they created to promote it.</p>
				<p>The first offense is the message when you first visit the page, "You need to enable JavaScript to run this app."
					Usually, when I see that message, I just close the tab.
					This time, I decided to push forward and enable JavaScript.</p>
				<p>The second offense is the fact that the page is indeed a page comprised mostly of text, not an "app" as previously described.
					It also does not contain an example of an ai.txt file anywhere, which is the only thing I actually wanted to see.
					Instead, there are a few bullet points that were probably written by a language model themselves and an embedded YouTube video with an incredibly slow talking voice that also doesn't show an example of an ai.txt file.</p>
				<p>There is also a generator to create your own ai.txt file.
					Apparently, if you want to use the generator, which is entirely client-side JavaScript, you must agree to the terms of service.
					The link to the TOS is not real.
					It doesn't show me the URL when I hover over it so it's using an event listener to open a new tab when it's clicked.</p>
				<p>When I click on the line of text resembling a hyperlink, it opens another page comprised entirely of text that will not display a single thing without enabling first-party JavaScript <i>and</i> XHR from a third-party website.
					What a clown show!</p>
				<h2>Appendix: More Offenses</h2>
				<p>You need to scroll down a full page to get any actual information.
					It's just a giant, irrelevant picture with a marketing tagline and a couple of buttons to scroll down.
					This is an inexcusable pattern in Web design that should be called out whenever it appears.
					Credit <a href="https://lyse.isobeef.org/twtxt.txt">@lyse@lyse.isobeef.org</a> on twtxt.
					I really should have picked up on this.</p>
				<p>There are a couple things I've realized since writing this post.</p>
				<ol>
					<li>The page has no DOCTYPE, so it's rendered in "Quirks mode" in Web browsers.
						Quirks Mode wasn't acceptable on Geocities, let alone a website in 2024 made by a real company with paid staff.</li>
					<li>The page does not tell you what their User-Agent string is, which is pertinent information.
						It looks like it's <tt>Spawning-AI</tt> according to @lyse@lyse.isobeef.org's logs.</li>
				</ol>
				<p><b>Updated 2024-01-25:</b> Added appendix, minor wording adjustments.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>Systemd: Unmount NFS before killing the Wireguard interface</title>
		<id>tag:mckinley.cc,2023:notes:202311013-nfs-wireguard-systemd</id>
		<link rel="alternate" href="/notes/202311013-nfs-wireguard-systemd.xhtml"/>
		<published>2023-11-03T17:36:14-07:00</published>
		<updated>2023-11-03T17:36:14-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>My laptop connects to an NFS share on my home server over Wireguard so I can access the files from anywhere.
					The NFS share is in <tt>/etc/fstab</tt> but isn't mounted automatically.
					The Wireguard interface is managed with wg-quick and started using the systemd template unit <tt>wg-quick@<i>ifname</i>.service</tt>.</p>
				<p>The setup works well.
					When I leave the house or come back, I change the endpoint for the Wireguard peer rather than remounting the NFS share.
					The NFS client stays happy and programs with open files are none the wiser.</p>
				<p>However, there was one little problem.
					Shutdowns would hang for 90 seconds if I didn't unmount the NFS share first.
					Systemd was bringing down the Wireguard interfaces before unmounting the network filesystems.
					This could probably be solved with the correct drop-in file, but I found a more elegant solution.
					Simply add <tt>x-systemd.requires=wg-quick@<i>ifname</i>.service</tt> to the mount options in <tt>/etc/fstab</tt>.</p>
				<p>I found the solution in a <a href="https://dhole.github.io/post/nfs_wireguard/">guide</a> on creating a similar setup over on dhole.github.io.
					There are some other interesting posts over there, so it's worth a look.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>The future of the Web, as of 2000</title>
		<id>tag:mckinley.cc,2023:notes:20231013-xhtml-for-dummies</id>
		<link rel="alternate" href="/notes/20231013-xhtml-for-dummies.xhtml"/>
		<published>2023-10-13T16:45:48-07:00</published>
		<updated>2023-10-13T16:45:48-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>I recently bought a copy of <i>XHTML for Dummies</i>, complete with the original CD-ROM.
					I enjoy old computer books and I wanted to lend it to a friend who is thinking about creating a personal website.</p>
				<p>It would only be half a joke.
					If he followed the instructions in the book, he would end up with a much better website than modern guides on Living Standard HTML and the latest ridiculous framework.
					The strict markup of XML would also stop him from developing bad habits.
					Of course, plain old HTML-without-the-X parsers will make it work no matter what you give them.</p>
				<p>Reading through the first part of the book, I noticed how optimistic it was.
					It was published in 2000, when XML was shiny and new, and the future for the Web was bright.
					After the book demonstrated the advantages of XHTML by inserting custom elements into a document using XML namespaces, this passage stood out to me.</p>
				<blockquote>So the question we should ask isn't whether XML will replace HTML, but whether XML-based documents (including XHTML) will replace SGML-based such as HTML?
					The answer to this is <i>inevitably</i>, although HTML 4.0 and its predecessors may be around for a few more years.</blockquote>
				<p><i>Sigh</i>.
					I wonder what Ed Tittel and the other authors of this book think about the state of the Web these days.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>You can't find a good new computer on Amazon</title>
		<id>tag:mckinley.cc,2023:notes:20231004-amazon-new-pc</id>
		<link rel="alternate" href="/notes/20231004-amazon-new-pc.xhtml"/>
		<published>2023-10-04T12:20:57-07:00</published>
		<updated>2023-10-04T12:20:57-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>Amazon is, possibly, the worst place to go if you're in the market for a new computer.
					Most of the listings are either new machines with 2-4 year old hardware or very old "renewed" machines you can find on eBay for half the price.</p>
				<p>In general, it's very difficult to compare prices on Amazon.
					In a market flooded with outdated products, the effect is multiplied.
					Sellers know this and will often wildly inflate the price in hopes of tricking Grandma.</p>
				<p>I don't like Amazon for other reasons and I wouldn't recommend using it at all.
					If you absolutely must buy a computer there, go to another website like bestbuy.com and find the one you want, then look for the same model on Amazon.
					You'll get a much better result.
					This trick will also work for just about every other product.</p>
				<p>Amazon also pushes a lot of new laptops with super low-end hardware like Intel Celeron CPUs.
					Many of these machines come in S Mode<sup id="fnref1"><a href="#fn1">[1]</a></sup> and some even have eMMC storage.
					Avoid them at all costs.
					Even some i3 and Ryzen 3 machines will have reduced longevity compared to those with i5s and Ryzen 5s.
					If that's all you can find in your price range, go buy a used higher-end computer from a few years ago.
					Amazon's used market is terrible, so go to eBay or Craigslist.</p>
				<p>Of course, it would be best to find a store locally or buy one online and pay in Monero.</p>
				<ol class="footnote">
					<li id="fn1"><a href="#fnref1">^</a>
						S Mode is an anti-feature of Windows that only permits you to run software from the Microsoft Store.
						It's also one of many traps in Windows designed to force you into a Microsoft account and all the baggage that comes with it.
						If you absolutely must use Windows, stay away from S Mode.</li>
				</ol>
			</div>
		</content>
	</entry>
	<entry>
		<title>How Microsoft's Trickery Works</title>
		<id>tag:mckinley.cc,2022-06-27:notes:microsoft</id>
		<link rel="alternate" href="/notes/20230529-mullvad.xhtml"/>
		<published>2023-06-27T20:52:46-07:00</published>
		<updated>2023-06-27T20:52:46-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>On the front page of HN today was the lastest from Microsoft's trickery department.
					It's also a prime example of how this sort of trickery works in general.</p>
				<p>When you click a link from an e-mail in Outlook, it will now open in Microsoft Edge.
					Don't worry, though, this isn't just to force you into using Edge.
					It's also going to open your e-mail in a side bar in Edge so you can easily switch between them.
					It's for your benefit!</p>
				<p>This is what they always do.
					They come up with a new way to push you into their system, whatever that is.
					Then, they make up a BS fraudulent "feature" nobody asked for to justify it.
					Finally, when they're accused of manipulating their users, they point to the fraudulent "feature" and write a page on their website like <a href="https://support.microsoft.com/en-us/topic/outlook-emails-open-next-to-web-links-in-microsoft-edge-b0e1a1c1-bd62-462c-9ed5-5938b9c649f0">this</a>.</p>
				<p>Every single person who has ever visited that page, apart from HN traffic, is there because they want to turn it off.
					Yet, the entire thing is dedicated to convincing you to leave it on.
					The steps to turn it off are buried in the FAQ, along with questions such as "How can I set Microsoft Edge as my Windows default browser?".
					What a joke.</p>
				<p>It's not just Microsoft, most technology companies do the same thing.
					They will keep getting away with it until you do something.
					At what point will you stop letting them disrespect you this way?
					Where is the line?</p>
				<p><b>P.S.</b> This is the kind of thing that happens when you have a herd of (very obedient) domesticated users.
					<a href="https://seirdy.one/posts/2021/01/27/whatsapp-and-the-domestication-of-users/">WhatsApp and the domestication of users</a> by Rohan Kumar is an excellent read about this subject.</p>
			</div>
		</content>
	</entry>
	<entry>
		<title>Mullvad to Remove Port Forwarding</title>
		<id>tag:mckinley.cc,2022-05-29:notes:mullvad</id>
		<link rel="alternate" href="/notes/20230529-mullvad.xhtml"/>
		<published>2023-05-29T14:08:18-07:00</published>
		<updated>2023-05-29T14:08:18-07:00</updated>
		<content type="xhtml">
			<div xmlns="http://www.w3.org/1999/xhtml">
				<p>Mullvad, my VPN provider of choice, has announced that they will <a href="https://www.mullvad.net/en/blog/2023/5/29/removing-the-support-for-forwarded-ports/">end support for port forwarding</a> on July 1st.
					This post is both a public service announcement and a way for me to express my disappointment in this decision.</p>
				<p>Port forwarding is an essential feature for me, and I'll have no choice but to switch to another provider.
					I've used Mullvad for over three years and I've never had a problem.
					They have an incredible reputation in the community as well, much better than other providers.</p>
				<p>I haven't lost hope yet.
					There are a number of other deeply disappointed customers posting on <a href="https://libreddit.nl/r/mullvadvpn">their subreddit</a>.
					Perhaps something will change between now and July.</p>
			</div>
		</content>
	</entry>
</feed>

