For a long time I’ve been thinking that I had to have a website. I even bought a domain… something like a year and a half ago. Yes, I’ve paid 2 yearly fees and still hadn’t done anything with it. That’s me. I chose IWantMyName when I registered mateos.io. I don’t really remember why, but I seem to recall they seemed less sketchy than other registrars.
I’ve considered several options for building the website, but all of them revolved around wordpress because I had heard it was extremely easy to use. My doubt was mostly whether to purchase a hosting + WordPress service like wordpress.com or to get a server in a hosting service and handle everything myself. That would have been fun and a great way to learn several things at once, but I don’t have the energy that used to let me spend a whole weekend configuring something or other in linux anymore. Also, managing something that sits wide open to the Internet sounds scary and like a lot of work to me… I’m not a sysadmin and I don’t want to be.
This morning I was feeling a little sick so I was snugly wrapped in a blanket on my sofa. As I was sipping an instant decaf made with almond milk (I know, it’s disgusting, but I had run out of real milk), I decided: let’s just get this done the simplest way possible. There’ll be plenty of time to swith to something more powerful or flexible if I do need it, but if I keep thinking about what is the proper way to do this without actually knowing anything about web development or deployment, I’ll be stuck in analysis paralysis forever.
My first step was to just go and check if I rememebered my username and password from my domain service. I did! And it’s surely not because I reuse passwords, which is a Very Bad Thing that I definitely do not do and of which you should be ashamed of if you do it. Once I was in, I noticed they offered a ‘Marketplace’, which was kind of confusing– aren’t they only registrars? Do they offer a managed WordPress install or something? Turns out it consists only of dns’ing your custom domain name to other services, but there was a little link to GitHub Pages and I got intrigued. Long story short, that’s how you’re reading this right now!
The good thing about Pages it that it can be as simple as you want. Push an .html file to your repo, and it shows up! No need to worry about hosting or wordpress or whatever. If you’re already using GitHub, is dead simple. As I read, I became more and more interested. Not only is it simple, but it can be made more flexible by using a static site generator like Jekyll, so there’s some room for growing. Also, it looks like it should be extremely easy to build a blog post from a Jupyter notebook, which is currently my go-to tool for exploration of any new topic. Also, apparently you can write latex from your markdown, somehow. Maybe I could even render my CV, which is currently a latex document, as html and put it there as is?? So many possibilities! So how did I do it?
First step, create a repo in github with the name username.github.io and clone it in your machine. You’ll need an index.html file on it for it to render: I just
$ echo 'Hello world' > index.html $ git add index.html $ git commit -m "Test simple index.html" $ git push
And boom! something I wrote is on the Internet!! magick!
Right now, it’s showing at https://danimateos.github.io, but I wanted to use the domain I’d bought more than a year before. Otherwise, what would be the point? The process is really easy. In https://iwantmyname.com/, you go to ‘Domains’, select on the one you want to add to your GitHub Page, and click on Install a new service. It will ask you for your GitHub username and prompt you to add your custom domain to your GitHub Pages account, which you do in the settings page for the repository.
And that’s it! Now my little hello world is at mateos.io, right where I wanted. But, how to build a proper website with the minimum amount of hassle? I’ll show that in my next installment, in which I’ll talk about Jekyll.