Skip to content

Instantly share code, notes, and snippets.

Avatar

Cies Breijs cies

View GitHub Profile
View elm-course-setup.md

Vereisten voor de Elm cursus

Korte link naar deze pagina: bit.ly/3kL1FIT

Ieder heeft een van de volgende twee setups nodig:

  • Met Elm en IntelliJ geinstalleerd (zie hier de installatie instructies):
    • IntelliJ met myproject open waar het plus min voorbeeld in staat
    • een terminal met elm repl (kun je stukjes testen)
View game-ideas.md

Simple games ideas for trying out Elm

For some of these game you will need "random numbers".

Here's the official guide on doing random in Elm. To get the example to work in Ellie you need to add a module definition on top (the compile error will guide you in the right direction) and add the Random package from the "Package" menu (see package icon) on the left.

The game ideas:

  • Write function that translates a text to Pig Latin and back.
@cies
cies / intro-to-elm.md
Last active Mar 5, 2021
A beginner's introduction to Elm (0.19.1)
View intro-to-elm.md

Elm: Elegant browser programs

Elm is a programming language that compiles to JavaScript (the main language understood by web browsers).

Contrary to some other programming languages (like C, C++, Java or Rust), Elm is not "general purpose", it is designed specifically to create web applications.

What makes Elm unique:

  • Easy to get started, as it...
@cies
cies / elm-course.md
Last active Mar 5, 2021
Prepare for the Elm Course
View elm-course.md

Install Elm and IntelliJ

For the course we will use the programming language Elm.

It is possible to use an online Elm environment name Ellie: in that case there is nothing for you to install.

But you can also install Elm and a code editor (IntelliJ) with the Elm plugin. This has some advantages:

  • You do not depend on the internet working
@cies
cies / exceptions.md
Last active Nov 8, 2019
Exceptions in general and in Java/Kotlin/TS in particular
View exceptions.md

Exceptions in general and in Java in particular

The use of exceptions for anything but unrecoverable errors is greatly contested in programming. In this article we try to shed some light on this matter. But before we start digging deeper, here some considerations:

  • Unrecoverable is not very well defined. Sometimes it makes sense for software to crash: print some final log lines, try to do some cleanups and abort. Sometimes it does not: when we are in some code that simply needs to fail hard at that particular task/job/request (and surely log the "bug hinting error") but remain in service. Unrecoverable could also mean: cannot continue without a retry.

  • There is a common phrase "exceptions should be used for exceptional conditions; things you don't expect to happen" which does not add much to the discussion. What is truly exceptional is about as vague as truly unrecoverable.

  • Some languages, notably Java (but not Kotlin!), allow for "checked" exceptions. In Java these checked exceptions (inheriting fr

@cies
cies / exceptions.md
Created Nov 7, 2019
xceptions in general and in Java/Kotlin/TS in particular
View exceptions.md

Exceptions in general and in Java in particular

The use of exceptions for anything but unrecoverable errors is greatly contested in programming. In this article we try to shed some light on this matter. But before we start digging deeper, here some considerations:

  • Unrecoverable is not very well defined. Sometimes it makes sense for software to crash: print some final log lines, try to do some cleanups and abort. Sometimes it does not: when we are in some code that simply needs to fail hard at that particular task/job/request (and surely log the "bug hinting error") but remain in service. Unrecoverable could also mean: cannot continue without a retry.

  • There is a common phrase "exceptions should be used for exceptional conditions; things you don't expect to happen" which does not add much to the discussion. What is truly exceptional is about as vague as truly unrecoverable.

  • Some languages, notably Java (but not Kotlin!), allow for "checked" exceptions. In Java these checked exceptions (inheriting fr

View userChrome.css
/* On Linux this file should be in:
~/.mozilla/firefox/$USER_ID.default/chrome/userChrome.css
To be used with the awesome Tree Style Tabs addon.
*/
/* Hide horizontal tabs at the top of the window */
@-moz-document url("chrome://browser/content/browser.xul") {
#TabsToolbar {
visibility: collapse !important;
@cies
cies / belasting_app_op_ubuntu.md
Created Jun 14, 2018
Het installeren van de Belastingdienst applicatie(s) op een recente (2018) Ubuntu versie
View belasting_app_op_ubuntu.md

Deze gist om mijn ervaring/oplossing te delen met het installeren van de Belastingdienst applicatie la2018ux op een recente Ubuntu. Wellicht dat dit ook werkt op Debian, geen idee.

Allereerst: samen on de Belastingdienst dat ze die app(s) alleen in 32-bit leveren, terwijl 64-bit al 10 jaar meer gangbaar is dan 32-bit. Ik raad iedereen aan om hier over te klagen (vraag of ze er een aantekening van maken en het doorgeven), dan gaan ze wellicht ooit voor ons marginaal kleine clubje zorgen! Maar ik verwacht dat ze een web app eerder afhebben, dan een 64-bit build.

Ik heb de .deb gedownload. Er stond iets verkeerd ingesteld waardoor mijn browser de inhoud van de .deb probeerde weer te geven. Ik heb de link gekopieerd en met wget dat ding gedownload.

Toen eerste poging:

sudo dpkg -i la2018_1.10_i386.deb
@cies
cies / SETUP.md
Created Dec 18, 2015
VM setup for Rails workshop
View SETUP.md

Rails Workshop VM

Welcome to this VM! Your username is railsws and your password (in case you need it, like when using sudo) is railsws as well.

Good luck and enjoy!

Pre-installed software (we did this for you)

Here a list of the pre-installed software on this VM.

@cies
cies / rails-workshop-preps.md
Last active Dec 28, 2015
Voorbereidingen voor de MVC web application workshop HRO 2015 @ Hoppinger
View rails-workshop-preps.md

In deze tekst vind je hoe je je kunt voorbereiden op de MVC web applicatie workshop die Hoppinger organiseerd op 11 januari 2016.

De alles-in-een Virtual Machine

Voor de cursus hebben we een Virtual Machine (VM) gemaakt, welke alles bevast om gelijk mee aan de slag te kunnen. Download de VM op de volgende link:

https://www.dropbox.com/s/bc2sqy9t3f6ohe4/rails-workshop-vm.ova?dl=0