Skip to content

Instantly share code, notes, and snippets.

View JonasGroeger's full-sized avatar
🏠
Working from home

Jonas Gröger JonasGroeger

🏠
Working from home
View GitHub Profile
@JonasGroeger
JonasGroeger / unattend.xml
Created August 29, 2019 13:45
Put next to python-xxx.exe to auto-install preconfigured python. https://docs.python.org/3/using/windows.html#installing-without-ui
<Options>
<Option Name="InstallLauncherAllUsers" Value="0" />
<Option Name="SimpleInstall" Value="1" />
<Option Name="PrependPath" Value="1" />
<Option Name="Include_test" Value="0" />
<Option Name="Include_doc" Value="0" />
<Option Name="Include_tcltk" Value="0" />
</Options>
@JonasGroeger
JonasGroeger / perf.sh
Last active May 7, 2018 15:39
Performancetest
bash -c "rm -rf /tmp/test-d/; mkdir -p /tmp/test-d; cd /tmp/test-d/; git init" 1>/dev/null
@JonasGroeger
JonasGroeger / OnShutdownCompressingRollingFileAppender.java
Created April 14, 2018 20:51
OnShutdownCompressingRollingFileAppender the compresses on logging context stop
package de.jonasgroeger.logback;
import ch.qos.logback.core.LogbackException;
import ch.qos.logback.core.rolling.RollingFileAppender;
import ch.qos.logback.core.rolling.RollingPolicy;
import ch.qos.logback.core.rolling.TimeBasedFileNamingAndTriggeringPolicy;
import ch.qos.logback.core.rolling.TimeBasedRollingPolicy;
import ch.qos.logback.core.rolling.helper.CompressionMode;
import ch.qos.logback.core.rolling.helper.Compressor;

Keybase proof

I hereby claim:

  • I am jonasgroeger on github.
  • I am jonasgroeger (https://keybase.io/jonasgroeger) on keybase.
  • I have a public key ASChemutzTh_F1v-seff00EIXO3DRuzZGd6cUWRMyGckowo

To claim this, I am signing this object:

@JonasGroeger
JonasGroeger / README.md
Last active June 2, 2017 10:52
Export iFiske data to a KML file

Steps to export iFiske data to a KML file

  1. Open Chrome on "http://www.ifiske.se/index.php/en/fishing-areas/karta"

  2. Press F12 and go to the "Console" tab

  3. Paste the following code:

    function Export_iFiske_To_KML() {
        var template = `
    <?xml version="1.0" encoding="UTF-8"?>
    <kml xmlns="http://www.opengis.net/kml/2.2">
    
@JonasGroeger
JonasGroeger / sync-projects
Last active November 22, 2025 10:34
Gitlab: Clone / Pull all projects in a group
#!/usr/bin/env bash
# Documentation
# https://docs.gitlab.com/ce/api/projects.html#list-projects
NAMESPACE="YOUR_NAMESPACE"
BASE_PATH="https://gitlab.example.com/"
PROJECT_SEARCH_PARAM=""
PROJECT_SELECTION="select(.namespace.name == \"$NAMESPACE\")"
PROJECT_PROJECTION="{ "path": .path, "git": .ssh_url_to_repo }"
quiet_update() {
DEBIAN_FRONTEND=noninteractive apt-get update -qq < /dev/null > /dev/null
}
quiet_install() {
DEBIAN_FRONTEND=noninteractive apt-get install -qq "$@" < /dev/null > /dev/null
}
quiet_install_no_recommends() {
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -qq "$@" < /dev/null > /dev/null
#!/bin/bash
#
# This script copies the contents of the block below into a file.
# Useful for self-extracting configuration files or the like.
#
# Author: Jonas Gröger <[email protected]>
#
<<DATASECTION