Skip to content

Instantly share code, notes, and snippets.

View jeroenvermeulen's full-sized avatar

Jeroen Vermeulen jeroenvermeulen

View GitHub Profile
@thekvs
thekvs / gist:7d2f29404d28c9c742bf3c825e1990f5
Last active June 4, 2024 19:17
Get latest release URL from GitHub using jq
curl --silent "https://api.github.com/repos/goreleaser/goreleaser/releases/latest" | jq -r '.assets[] | select (.name|test("amd64.deb")) | .browser_download_url'
curl --silent "https://api.github.com/repos/goreleaser/goreleaser/releases/latest" | jq -r '.assets[] | select (.name|test("Linux_x86_64.tar.gz")) | .browser_download_url'
@wido
wido / ip6-eui64-address.py
Created November 13, 2019 10:41
Calculate RFC482 (SLAAC) IPv6 address a host will obtain
#!/usr/bin/env python3
#
# Calculate the IPv6 address a host will obtain per RFC4862
#
# Usage: ./ip6-eui64-address.py --prefix 2001:db8::/64 52:54:00:59:c2:b3
#
# Author: Wido den Hollander <wido@denhollander.io>
#
import argparse
import ipaddress
@superboum
superboum / LICENCE.txt
Last active May 29, 2024 19:09
Install Debian with Debootstrap + Grub EFI
MIT LICENSE
Copyright 2018 Quentin Dufour
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR TH
@dcasati
dcasati / export-kubeconfig-from-aks
Created February 6, 2018 15:30
Export KUBECONFIG from AKS
az aks get-credentials --resource-group k8s-demo-ss --name k8s-demo-cluster-ss --file kubeconfig-ss
@Kovrinic
Kovrinic / .gitconfig
Last active July 15, 2024 04:45
git global url insteadOf setup
# one or the other, NOT both
[url "https://github"]
insteadOf = git://github
# or
[url "git@github.com:"]
insteadOf = git://github
@boseji
boseji / wdt_sleep.ino
Created December 16, 2016 13:37
Arduino Pro Mini Low power Sleep Example
/**
* Arduino Pro Mini Low power Sleep Example
*
* @license BSD Open Source License
* Copyright (c) 2004-2021 Abhijit Bose &lt; salearj [at] hotmail [dot] com &gt;
* If you require a license, see
* http://www.opensource.org/licenses/bsd-license.php
*
* @note
* This example show how to properly enter sleep mode and wake up
@filipenf
filipenf / lndupes.py
Created August 19, 2016 19:04
Reads fdupes(-r1) output and create relative symbolic links for each duplicate
#!/usr/bin/env python
# Reads fdupes(-r -1) output and create relative symbolic links for each duplicate
# usage: fdupes -r1 . | ./lndupes.py
import os
from os.path import dirname, relpath, basename, join
import sys
lines = sys.stdin.readlines()
@thisismitch
thisismitch / haproxy.cfg
Last active July 25, 2024 03:38
Let's Encrypt Auto-Renewal script for HAProxy
global
log /dev/log local0
log /dev/log local1 notice
chroot /var/lib/haproxy
stats socket /run/haproxy/admin.sock mode 660 level admin
stats timeout 30s
user haproxy
group haproxy
daemon
maxconn 2048
@demagu
demagu / Could-not-restore-untracked-files-from-stash.md
Last active September 8, 2022 17:28
Could not restore untracked files from stash

How to fix 'Could not restore untracked files from stash' issue

Convert a stash to a temporary branch

git stash branch STASHTEMPBRANCH

Apply your stash

git stash apply

@mpchadwick
mpchadwick / Mpchadwick_Missing_Acl_Checker.php
Created July 11, 2015 03:42
Mpchadwick_Missing_Acl_Checker.php
<?php
require_once 'abstract.php';
/**
* Generate a CSV of modules with admin routes that haven't implemented _isAllowed()
*/
class Mpchadwick_Missing_Acl_Checker extends Mage_Shell_Abstract
{
const MODULES_PATH = 'modules';