2015-10-01

Why I don't use Linux

Prepare for a rant about backward compatibility.

Despite being a programmer that primarily works in C++, I'm a Windows user. I'm not ignorant though, I know my way around Linux thanks to VMs and Travis CI. I'm not particularly happy with Windows - it's a nightmare for developing C++ - but I just can't see myself using a Linux operating system full time or even part time. Windows does one thing right that Linux does wrong: programs are self-contained.

On Windows, when you install a program, all files that are not temporary or specific to any one user go into a single folder. Don't want that software anymore? I would say just nuke the folder, but there are freaky things like the Registry, Services, Shortcuts, etc. that are really best dealt with by an Uninstaller. So Windows is not perfect. But in my opinion, Linux has it worse: when you install an application, files get distributed everywhere. There's /bin, /sbin, /usr/bin, /opt/, lib folders, etc. and it makes it really confusing to know where to look for a program's files.

Not only that, but the files are mixed in with other applications! That's horrible design! What if Program X won't work if Program Y is in PATH? Sorry, you're screwed! What if Program Z and Program W have an executable with the same name? Sorry, you're screwed! What if Program Q has dozens of executables and something isn't working because one is in the wrong location? Sorry, you're screwed! (PATH in and of itself is an insanity, but at least the user can control it kind of easily.)

Both systems are bad, but Windows is at least bearable. I'm not the only one with this opinion - people know Linux's directory layout sucks. There's also GoboLinux, a flavor of Linux that actually does something to remedy the problem by isolating program files. See? People saw a problem and it was significant enough to them that they decided to go through all the effort of modifying the operating system itself to fix the problem. This isn't a light issue, it's something people actively have to deal with every day.

Also, there seems to be no current standard for having multiple versions of a program installed at the same time. On Windows, some applications append the version number to the name of the folder they install into, which works fine but doesn't organize all the versions into a common folder for convenience. On Linux, you're screwed! People just append the version number to all the files for the program, because if not, conflicts would happen and you'd be even more screwed!

Most of these problems are due to decisions made decades ago that are long beyond complaining about, but that doesn't mean innovation has to be stifled! Operating systems are so worried about backward compatibility so as to not fix the mistakes of the past, and yet companies are still running ancient operating systems and software because backwards compatibility gets broken anyway! Why even bother trying to be backwards compatible if you can't even do it right!? Just fix what needs fixing and improve what needs improving! The world will have a huff and a puff and then adapt - the huffing and puffing will be smaller if the break in backward compatibility actually fixes fundamental underlying problems instead of just changing the layout of the Start Menu.

The only way technology seems to move forward is by reinventing an existing thing instead of just fixing what we already have. This is incredibly wasteful! It's a mess: people are too afraid to fix what's broken so instead they completely reinvent everything just to keep the broken stuff broken in the same way and the new stuff not broken for a little while.

I'm very passionate about technology, but I keep seeing this same trend over and over. Randall Munroe puts it pretty well. Sadly, I don't know how to fix it - I can only contribute to the chaos of competing standards. At the very least, now you know why ninjas don't use Linux.

UPDATE: for yet more reasons I avoid using linux except in virtual machines, read this article.

2015-09-11

Travis Rant

I need to rant.

Travis is Continuous Integration software for GitHub - as you push code to your repository, it builds and tests it for you using a script you configure yourself. It works great...if you're using tech from half a decade ago. It's horribly outdated, and the only solution is to update its software yourself in your script.

I primarily write C++, and I pretty much always use modern C++ (C++11 and C++14). Setting up travis for my projects is an absolute nightmare, and I'm giving up. Travis is falling way behind in the world of C++ and I'm tired of fixing their machines for them.

Travis uses CMake 2.8.7 when CMake 3 has been out for ages.
Travis uses clang 3.4 when clang 3.6 has been out for ages.
Travis uses gcc 4.6.3 when gcc 5 has been out for ages.

It is completely unacceptable. The particular versions of software that Travis uses seem to have been specifically hand-picked so as to make it impossible to compile C++11 or C++14 code. One has to manually update the software either by downloading pre-built binaries to the machines or actually compiling the newer versions from source. This makes the builds take forever and adds so much complexity to the build script that you will spend hours tweaking it until it finally works, not to mention having to research how to do all of it and then repeatedly pushing commits to your repository and waiting for travis to build and fail over and over and rinse and repeat and test your patience. I give up.

I appreciate that Travis is free to use by anyone, but I'm so tired of mucking around with my scripts for hours to work around the mess that is the machines the builds run on. After seeing how Travis has handled the situation, I don't ever want to give them my money.

Thankfully, there are alternatives, and ninjas know how to try them out.


2015-07-30

Windows 10 Upgrade Nightmare

I love Windows 7, and I was hyped for Windows 10. So naturally, I was one of the first few people to reserve the upgrade when the icon appeared in my system tray - I was actually awake at the time. Two months rolled by, and I decided to, for the first time ever, use the built-in disk cleanup tool, which claimed it could free up over 42GB. Unfortunately, my filesystem was horribly corrupted and it destroyed my system beyond repair. I had to wipe my machine and reset it to its out-of-the-box state using the built-in system restore from the boot screen. Windows 10 hadn't launched yet, so I thought all I had to do was install a couple hundred updates and reserve my upgrade again.

Unfortunately, it turned out to be more complicated than that. Somehow by uninstalling the bloatware again, I bricked Windows Update - it wouldn't even open. Time for another few hours of resetting the system. Then, I installed 200+ updates and only had a few left, but somehow the BITS, the Background Intelligent Transfer Service that Windows Update uses to download updates, was broken. I spent 10+ hours trying everything I could find on the internet to fix it, to no avail. I had reserved my Windows 10 upgrade again, but since BITS was required to download it, I was screwed again.

By now Windows 10 had launched. I wiped my system again and installed the 200+ updates again. No Windows 10 icon in taskbar this time. I spent more hours trying various scripts and tricks from online to no avail. Finally, I found out about the manual upgrade process. I chose to not keep any data or software (so as to easily discard the bloatware) and finally, after four days, my computer was upgrading to Windows 10. I'm using it right now, and it's great.

That's not the end of the story though. Being that I'm still in college and it is between semesters, I live in a house with two other people who wanted to upgrade to Windows 10 - my mom and my sister. I'm the resident tech guy around here, so I was working on their computers in parallel to mine.

My sister's computer was relatively new, just bought a few months ago. When I ran sfc /scannow, it found corrupted files that it couldn't fix. I prayed that the upgrade wouldn't care, but I wasn't sure. As soon as the upgrade was made available, the icon vanished from her system tray. Again, I spent hours trying to make it come back, to no avail. Windows Update still claimed her update was reserved, but it wouldn't download it, and I feared the corrupted files were the issue. We backed up all her data, used the built-in factory reset, and had the same issue as me where after all the updates the icon would not appear. The manual upgrade did the trick.

My mom probably had the best experience out of all of us. The upgrade failed the first two times, and I feared it was because she also has corrupted system files that couldn't be fixed. However, some Googling online of the error code revealed that people had problems when upgrading to Windows 8/8.1 when there were corrupted user profiles or profiles on external drives. Since the computer used to be a shared computer, it had profiles for myself and my sister alongside my mom's. I deleted them, disconnected the external drive, and tried the upgrade again. Tada! It worked, and my mom was able to do an in-place upgrade, keeping all her files and software intact.

Moral of the story: if you have issues with the Windows 10 in-place upgrade, I strongly recommend just clouding all your data and doing the manual upgrade. If you don't mind reinstalling and redownloading everything, I suggest also choosing not to keep any data or software so that you can go with a pure vanilla Windows 10 installation (and leave behind whatever bloatware has been sitting on your computer for ages).

I don't offer technical support online or in the comments, by the way - you still need Google for that.

2015-06-27

History Overload

History Overload

I thought this tool wouldn't get much traffic. Mojang's restrictions seemed reasonable - 600 requests per 10 minutes? That's a request every second; no way I'll reach that load. Except I am reaching that load. All the time. Apparently if you Google search "Minecraft Name History" this is one of the first few results. That's what I get for spreading the word, I guess.

Caching isn't a trivial problem - there are all sorts of nuances with Mojang changing offensive names before the 30 day period, etc, and I don't even have anywhere to cache information to. I hacked the script together in an hour in really horribly written PHP code that should never be in any production environment. It's not worth the effort to me when other tools exist and work better.

I don't want people finding a broken dysfunctional service at the top of their Google search results - it's an inconvenience to everyone. So I've decided: I'm shutting down this service. It was great while it worked, but other services exist that have solved the caching problem in their own ways. Just use Google to find them - they're right under my result (for now - hopefully my result fades away).

The source code will always be available on GitHub.

2015-06-04

I'm mostly vicarious

I enjoy experiencing many things through others - that is, I enjoy living life vicariously. (Not everything, of course. Just a lot of things compared to other people.) I don't feel happy doing things myself - instead I get more enjoyment out of seeing other people do things.

Most of the games I own I have not played fully, simply because it is more enjoyable to watch Let's Plays instead. (Plus you can watch LPs at 2x speed.) I generally buy games when I want to reward the developers for their hard work, not when I actually want to play the game myself.

Life is too short and there are too many things to do. I find it easier to watch what other people do and skip the boring parts. I generally watch YouTube videos at 2x speed, and I'm usually doing something else at the same time (writing code, writing blog posts, recording for my channel, reading other people's code, reading other people's blog posts, etc). For a long time I had AdBlock enabled on YouTube to save time, but I decided that I want to support the people I watch more than I want to save time, so I disabled it. (Fun fact: until the fixed it, you could watch a YouTube video at 2x speed and the mid-roll and post-roll ads would also play at 2x speed - then if you navigated to another video it also plays at 2x speed meaning the pre-roll ad plays at 2x speed as well. (But then in the middle of my Watch Later playlist it got fixed right before my eyes.))

To those of you who are not vicarious and who actually do things and make videos of yourself doing said things: thank you for your good showmanship, I appreciate it. It's the people like you that will move society forward. I'll just quietly follow along, contributing to society whenever I have sudden strokes of passion. (90% of all my hobbyist code has been the result of sudden passion or inspiration.)

Sure, I'm a coward, but that's exactly what ninjas are not, and I'm totally not a ninja.

2015-06-03

"Garbage Collection is Wrong" Explained

My other website, LB-Stuff.com, has been the primary target for my sudden urges to write articles on various things. People keep calling them blog posts (they're not), so I finally decided to make an actual blog (you ninjas are reading it right now). I figured "Eh, I like writing, and it's more comfortable than verbal communication like in my Minecraft LP videos", so why not?

The first article I wrote on my site was titled "Garbage Collection is Wrong". Dear god, what was 17-year-old me thinking? It was unintentional flamebait that ended with me having to put in a banner explaining that I didn't really know what I was talking about because I was just a teenager. Well, now I'm 20 and I still regret writing that article. I don't dare erase it, however. Sure, I often edit my forum posts dozens of times after submitting them and occasionally delete them mere seconds afterward (I am pretty impulsive sometimes and quickly regret the things I say), but I'm afraid that deleting the page would generate the wrong response. (Specifically, not a 404 or 410.)

I often write in moments of passion, but I've learned over the years that I have a lot of cognitive dissonance. There's a lot of good ideas floating around in my head, and a lot of bad ones too. I don't spend too much time thinking about them, so when I finally bring them together in a moment of passion to try and form an argument, the result is... a mess. My first mess was the garbage collection article.

My stance now is that GC is often used in scenarios where it is not beneficial - there are good use cases for GC, but there are more incorrect uses. But like anything related to computers, people will find a way to make it work better, and GC is decently fast nowadays. I still don't like it, but at least I've learned not to talk about things I am not very knowledgeable about. Internet people are ferocious, feral beasts that tear you to shreds at the first sign of an opinion.

Let this be a warning: I have very unique opinions. Do ninjas have unique opinions? I totally wouldn't know.