Skip to content

Instantly share code, notes, and snippets.

Maik Riechert letmaik

Block or report user

Report or block letmaik

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
letmaik /
Last active May 10, 2019
Using travis_retry inside shell scripts together with set -e

If you want to use travis_retry from within your own shell script files then you first have to make the travis_retry shell function available by sourcing the file, otherwise you just get a "command not found" error. See for a full example.

Note that the original function as found in the travis-ci/travis-build repository was slightly modified to allow it to be used in a shell context where set -e is enabled.

For reference, a tweet by Travis CI saying that you should copy the travis_retry code as I've done here:

letmaik / CartesianProduct.ps1
Created Apr 27, 2017
Cartesian product with keys (cross join) in PowerShell
View CartesianProduct.ps1
function CartesianProduct {
[Parameter(Mandatory = $true, ValueFromPipeline = $true)]
$values = @{ Foo = 1..5; Bar = 1..10}
$keys = @($values.GetEnumerator() | ForEach-Object { $_.Name })
$result = @($values[$keys[0]] | ForEach-Object { @{ $keys[0] = $_ } })
if ($keys.Length -gt 1) {
letmaik / symlinks.psm1
Created Mar 8, 2017
Create symlinks to folders and files on Windows without admin privileges in Powershell
View symlinks.psm1
letmaik /
Last active Jan 19, 2017 — forked from gesquive/
Methods to print out boost::program_options objects (C++11)
#include <string.h>
#include <iostream>
#include "boost/program_options.hpp"
#include "boost/filesystem.hpp"
#include "boost/any.hpp"
namespace po = boost::program_options;
inline void PrintUsage(const boost::program_options::options_description desc) {
std::cout << "Usage: " << app_name << " [options]" << std::endl;
letmaik / index.html
Created Oct 7, 2016
Leaflet GridLayer example with Canvas
View index.html
<!DOCTYPE html>
<title>GridLayer Test</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="" />
body {
padding: 0;
margin: 0;
letmaik / index.html
Last active Oct 28, 2016
CovJSON minimal visualization example
View index.html
<!DOCTYPE html>
html, body, #map {
width: 100%; height: 100%;
margin: 0;
letmaik / 0_input.jsonld
Last active May 12, 2016
GeoDCAT-AP Sandbox JSON-LD framing
View 0_input.jsonld
"@graph": [{
"@id": "",
"@type": "",
"": [{
"@value": "2015-12-03",
"@type": ""
"": [{
"@value": "Spatial resolution (equivalent scale): 1:1000",
letmaik / ndarray.html
Created Aug 16, 2015
Fun with ndarray and canvas
View ndarray.html
<!DOCTYPE html>
<canvas id="canvas" width="300" height="300"></canvas>
<script src=""></script>
System.import('npm:ndarray').then(function(ndarray) {
System.import('npm:ndarray-warp').then(function(warp) {
var canvas = document.getElementById('canvas')
var w = canvas.width
letmaik / test.html
Created Jul 26, 2015
Performance of DataView vs inline code for little/big endian conversion (inline wins)
View test.html
<!doctype html>
DataView: <span id="time_dataview"></span><br />
Inline: <span id="time_inline"></span>
var littleEndian = (function() {
letmaik / theme-37093.xml
Last active Aug 29, 2015
Eclipse Color Theme (Obsidian variation, esp. for Java)
View theme-37093.xml
<?xml version="1.0" encoding="utf-8"?>
<colorTheme id="37093" name="Obsidian Java" modified="" author="Maik">
<searchResultIndication color="#616161" />
<filteredSearchResultIndication color="#616161" />
<occurrenceIndication color="#616161" />
<writeOccurrenceIndication color="#616161" />
<findScope color="#E0E2E4" />
<deletionIndication color="#E0E2E4" />
<sourceHoverBackground color="#FFFFFF" />
<singleLineComment color="#7D8C93" />
You can’t perform that action at this time.