Skip to content

Instantly share code, notes, and snippets.

View StefanHeimberg's full-sized avatar

Stefan Heimberg StefanHeimberg

View GitHub Profile
@StefanHeimberg
StefanHeimberg / nsmb.conf
Created February 9, 2023 22:38 — forked from jbfriedrich/nsmb.conf
macOS 11.2 NSMB configuration
# /etc/nsmb.conf - macOS 11.3 - 2021-04-29
#------------------------------------------------------------------------------
# SMB configuration for macOS 11.3 <-> Synology
#------------------------------------------------------------------------------
# Additional information:
# -----------------------
# https://support.apple.com/de-de/HT211927
# https://support.apple.com/en-us/HT208209
# https://apple.stackexchange.com/questions/309016/smb-share-deadlocks-since-high-sierra
# https://photographylife.com/afp-vs-nfs-vs-smb-performance
@StefanHeimberg
StefanHeimberg / angular-cli-node-js-typescript-rxjs-compatiblity-matrix.csv
Created January 1, 2022 10:49 — forked from LayZeeDK/angular-cli-node-js-typescript-rxjs-compatiblity-matrix.csv
Angular CLI, Angular, Node.js, TypeScript, and RxJS compatibility matrix. Based on changelogs, metadata, and hands-on experience. Major Node.js and RxJS versions above officially supported versions are not listed. Note that minor TypeScript versions also contain breaking changes.
Angular CLI version Angular version Node.js version TypeScript version RxJS version
1.0.0-beta.17 (package name: angular-cli) 2.0.x 6.9.x or later minor version 2.0.x 5.0.x or later minor version
1.0.0-beta.20-1 (package name: angular-cli) 2.1.x 6.9.x or later minor version 2.0.x 5.0.x or later minor version
1.0.0-beta.22-1 (package name: angular-cli) 2.2.x 6.9.x or later minor version 2.0.x 5.0.x or later minor version
1.0.0-beta.30 2.3.x 6.9.x or later minor version 2.0.x 5.0.x or later minor version
1.0.0-rc.4 2.4.x 6.9.x or later minor version 2.0.x 5.0.x or later minor version
1.0.6 4.0.x/4.1.x 6.9.x or later minor version 2.2.x 5.0.x or later minor version
1.1.3 4.0.x/4.1.x 6.9.x or later minor version 2.3.x 5.0.x or later minor version
1.2.7 4.0.x/4.1.x 6.9.x or later minor version 2.3.x 5.0.x or later minor version
1.3.2 4.2.x/4.3.x/4.4.x 6.9.x or later minor version 2.4.x 5.0.x or later minor version
@StefanHeimberg
StefanHeimberg / generate_version_txt.sh
Last active September 18, 2021 22:08
Script to generate semver version.txt from maven and git. Can be used in CI such as Bamboo or Jenkins
#!/usr/bin/env bash
# author: Stefan Heimberg <kontakt@stefanheimberg.ch>
# download url: https://gist.github.com/StefanHeimberg/c19d7665e8df087845c036fe8b88c4f2
# version: 0.7
# usage:
# for maven based projects:
# - ./generate_version_txt.sh
# - ./generate_version_txt.sh <BUILD_NR_FROM_CI>
@StefanHeimberg
StefanHeimberg / README.md
Created June 9, 2021 18:53 — forked from zoilomora/README.md
How to disable cloud-init in Ubuntu

How to disable cloud-init in Ubuntu

Prevent start

  • Create an empty file to prevent the service from starting

      sudo touch /etc/cloud/cloud-init.disabled
    

Uninstall

@StefanHeimberg
StefanHeimberg / CDIUtil.java
Last active September 2, 2018 21:39
java ee 6 lookup utilities
package com.github.stefanheimberg.example.support;
import javax.enterprise.context.spi.CreationalContext;
import javax.enterprise.inject.spi.Bean;
import javax.enterprise.inject.spi.BeanManager;
public final class CDIUtil {
public static <T> T lookupByName(final String name) {
final BeanManager bm = getBeanManager();
#!/bin/bash
set -e
remoteCall="BAMBOO_URL/api/rest/updateAndBuild.action?buildKey=PLAN_KEY"
echo "Detected last directory that was committed ... triggering $remoteCall"
curl --connect-timeout 10 --max-time 10 --silent --fail $remoteCall > /dev/null
exit 0
#!/bin/bash
docker system prune -f
@StefanHeimberg
StefanHeimberg / docker-compose-tick.yml
Created March 14, 2018 09:58 — forked from cdelaitre/docker-compose-tick.yml
Monitor Docker Swarm with the InfluxData TICK Stack
version: '3'
services:
# FRONT
chronograf:
# Full tag list: https://hub.docker.com/r/library/chronograf/tags/
image: chronograf
deploy:
replicas: 1
placement:
constraints:
@StefanHeimberg
StefanHeimberg / API.md
Created September 15, 2017 20:54 — forked from iros/API.md
Documenting your REST API

Title

<Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).>

  • URL

    <The URL Structure (path only, no root url)>

  • Method:

https://help.github.com/articles/changing-author-info/
#!/bin/sh
git filter-branch --env-filter '
OLD_EMAIL="your-old-email@example.com"
CORRECT_NAME="Your Correct Name"
CORRECT_EMAIL="your-correct-email@example.com"