Skip to content

Instantly share code, notes, and snippets.


Matti Schneider MattiSG

View GitHub Profile
MattiSG /
Last active Mar 14, 2020
Traduction des recommandations d'éthique clinique italiennes pour le traitement COVID19 en saturation

Recommandations d'éthique clinique pour l'admission et la suspension d'un traitement intensif dans des conditions exceptionnelles de déséquilibre entre les besoins et les ressources disponibles

Version 01, publiée le 06/03/2020, traduite par DeepL.

Les prévisions de l'épidémie de coronavirus (Covid-19) actuellement en cours dans certaines régions italiennes prévoient une augmentation des cas d'insuffisance respiratoire aiguë (nécessitant une hospitalisation dans l'unité de soins intensifs) dans les prochaines semaines dans de nombreux centres, d'une ampleur telle qu'elle détermine un énorme déséquilibre entre les besoins cliniques réels de la population et la disponibilité réelle des ressources intensives. Il s'agit d'un scénario dans lequel les critères d'accès aux soins intensifs (et de sortie) pourraient être nécessaires non seulement p

MattiSG /
Created Jun 20, 2018
New Zealand activities watchers
# watch for some deal
while ! curl -s "$ACTIVITY_ID&_=1520111680085" | grep deal
sleep 60
MattiSG /
Last active Nov 24, 2017
Machine-readable map of human languages to countries they are spoken it, based on Wikipedia data

Source data is Wikipedia, so I think this stuff is CC-BY-SA. If any rights are attributed to me for formatting, I waive them all. The parser itself is under WTFPL.

MattiSG /
Last active Jun 22, 2019
Great Firewall of China

Experiments in circumventing state censorship

All tests done in October 2017 in mainland China (several provinces).

Good reference:


  • The Trying to download a VPN.log file shows that some files are fingerprinted and are blocked even over an encrypted SSH connection. No idea how that is possible. Please leave a comment or send me an email if you have a clue.
MattiSG / extract-formats.xsl
Created Jul 7, 2017
List XML attributes values
View extract-formats.xsl
<xsl:stylesheet version="1.0" xmlns:xsl="">
<xsl:template match="*">
<xsl:for-each select="@format">
<xsl:text>format: </xsl:text>
<xsl:value-of select="."/>
<xsl:for-each select="@type">
<xsl:text>type: </xsl:text>
MattiSG / ressource-types.js
Created Apr 24, 2017
Evaluate valid OpenFisca names from a list
View ressource-types.js
var ressourceTypes = [
MattiSG /
Last active Feb 25, 2020
Deploy bot

Continuous deployment with Git and SSH

This article presents how to deploy continuously from a Git repository with high security, by creating a UNIX user whose only purpose and ability is to update a repository and execute commands from a script within the repository upon successful SSH connections.


Your server has at least Git and some SSH agent installed, and you are connected to it as root.

Just to rephrase: all these commands are to be executed on your server, as root. ssh root@YOUR_SERVER now!

MattiSG /
Last active Nov 3, 2016
How to get thumbnails on webpages

How to get thumbnails on pages

MattiSG /
Last active Mar 23, 2021 — forked from fyrk/
Convert a wiki from MediaWiki to Gollum and Markdown, importing all metadata.

This will convert a wiki from MediaWiki to Gollum and Markdown (or any other format supported by Pandoc).

  1. Install dependencies:

    brew install pandoc icu4c
    gem install --no-ri --no-rdoc hpricot gollum gollum-lib pandoc-ruby
  2. Perform a Special:Export

MattiSG /
Last active Feb 5, 2016
ChromeDriver issue reproduction

With a running ChromeDriver:

git clone
npm install selenium-webdriver
node index.js