Excellent Series of Articles on Modern C++

Here is a great series of articles on modern C++:

  1. Relation between C and C++, Strings
  2. Namespaces, Classes, RAII, Smart pointers, Threads, Locking, Error Handling
  3. Inheritance & polymorphism, Templates
  4. Lambdas, Containers and algorithms, Boost containers
  5. Memory management, RVO, Smart Pointers
  6. Static assert, Constexpr, Time, Enums, Initializer Lists, Regexp, Optionals

posted on April 5, 2019development


Automated building with CircleCI

I've started using CircleCI to automatically build repos - specifically my various static websites. It's working really well. CircleCI will detect a change to the Github repo, automatically trigger a build and then push the result to the gh-pages branch.

One tip I found useful is to use a machine account to push to the gh-pages branch - this means that we don't need to use our actual github SSH key. You will need machine accounts in [both[(https://github.com/DevProgress/onboarding/wiki/Using-Circle-CI-with-Github-Pages-for-Continuous-Delivery) Github and CircleCI. For each repository that you want to build you need to add the machine account as a collaborator on the Github repository.

CircleCI will also trigger a build on the push to the gh-pages branch which is not what you want. To stop this we need to add [ci skip] to our commit message. In Middleman we can do this by adding deploy.commit_message = "Automated commit at #{time} by #{signature} [ci skip]" to our config.ru.

posted on October 2, 2018development


Tldr looks great as a simplified version of man. Example based rather than pages of options.

posted on August 21, 2018microposts


Misc HTML Links

Some links gathered while adding content to my chess site

posted on October 24, 2017development


My son is starting to learn Irish at school and I'm keeping track of the phrases he learns each week here.

posted on October 24, 2017microposts


Final Fantasy Speedruns

Got hooked on this Final Fantasy 7 speedrun. The strats are incredible. How they manage the step count is beyond me.

And here's a run for FF8 which looks good. Again this step counter stuff takes incredible skill.

Loved those two Final Fantasy games in particular. Series high point for me - apart from 12 they never hit those heights again.

posted on October 22, 2017gaming


Apple and Gaming

This was an excellent post by Dan Masters on how Apple messed up gaming on iOS. At the time the App Store came out, I remember that pundits were questioning if Nintendo had a future and not only that, if even dedicated portable consoles had a future.

The success of the Switch has put that to bed, but it would have been interesting to see what would have happened if Apple had really shown an interest in gaming. They had huge advantages e.g. hardware, iOS, account system but threw it away by not executing on those advantages.

The App Store for games has devolved into a two-bit fremium store which seems really strange compared to the high quality which they pride themselves on in their hardware. I understand that this is a strategy - commoditize your complements but that seems shortsighted. Their brand is a premium one and they are happy for it to be associated with junk apps. Nintendo has a high quality brand in software and will be able to sell Mario and other games for 50-60 euro each for some time to come.

posted on October 3, 2017gaming


Sublime Text Vintage Mode

I started learning Vim recently and it works fantastically well on Linux. Windows is a bit of a mess though and I'm not confident of getting plugins working correctly. Maybe the new Linux subsystem for Windows will help this.

In the meantime I've enabled vintage mode on Sublime Text and it seems to be working well. The main thing it gives me is the keyboard navigation keys. Not having to use the mouse or arrow keys is a big win. I never realised how good it would be until I tried it.

References: Sublime Text Docs, King Luddite Blog Post

posted on June 1, 2017development


New album from Lazerhawk. Great stuff

posted on February 26, 2017microposts


Converting Yaml to JSON in JavaScript

I use the Middleman data files feature for my chess site. These files are written in yaml. I could have used json directly for these which would have removed the need for this post but I find yaml is easier for manual editing - with json you constantly have to worry about matching up brackets. From the Middleman erb files, when I build locally I am able to access things like data.fide.ratings. However I would like to be able to load this data remotely and process it from my javascript code.

To load the remote file I just use the JQuery Ajax get function and pass it the url of the file that I want. Then I use the js-yaml library to parse the result and create a data json object from this. Now from my JavaScript code I am able to access the same data using the same notation.

function loadYamlFromUrl() {
    $.get( "https://raw.githubusercontent.com/gerardcondon/chess/master/website/data/ratings.yaml", function( data ) {
        var data = jsyaml.load(data);
        // can now access data.fide etc
    });
}

This has worked well for me and for any data file that I was able to access via Middleman, I can now access the same data from JavaScript in the same format.

posted on February 25, 2017development


Tags

By year

  1. 2020 (14)
  2. 2019 (17)
  3. 2018 (2)
  4. 2017 (11)
  5. 2016 (3)
  6. 2015 (6)
  7. 2014 (3)
  8. 2013 (11)
  9. 2012 (25)