Skip to content

Instantly share code, notes, and snippets.

View tbreuss's full-sized avatar
🚴‍♂️
Biking

tebe tbreuss

🚴‍♂️
Biking
View GitHub Profile
@tbreuss
tbreuss / docker-enc2ly.md
Last active January 1, 2021 16:14
Converting Encore files to LilyPond using Docker

This is a solution to run the original enc2ly CLI program within a Docker container.

There are two CLI programs that convert Encore musical files to LilyPond.

Unfortunately I wasn't able to run these programs on my MacOS.

So, here are the instructions for using the original enc2ly CLI programm within a Docker container.

@brandonros
brandonros / preact-htm-example.html
Last active August 9, 2024 04:32
Preact + Hyperscript Tagged Markup (HTM) example
<!DOCTYPE html>
<html>
<head>
<title>Preact HTM Example</title>
</head>
<body>
<script type="module">
// 1. imports from unpkg.com
import * as Preact from 'https://unpkg.com/[email protected]/dist/preact.module.js'
import htm from 'https://unpkg.com/[email protected]/dist/htm.module.js'
@Mrxchaoz
Mrxchaoz / Function.Array-Group-By.php
Created January 21, 2020 02:47 — forked from mcaskill/Function.Array-Group-By.php
PHP : Groups an array by a given key
<?php
if (!function_exists('array_group_by')) {
/**
* Groups an array by a given key.
*
* Groups an array into arrays by a given key, or set of keys, shared between all array members.
*
* Based on {@author Jake Zatecky}'s {@link https://github.com/jakezatecky/array_group_by array_group_by()} function.
* This variant allows $key to be closures.
@pyrou
pyrou / docker-compose.yml
Last active October 15, 2024 13:55
Use https://traefik.me SSL certificates for local HTTPS without having to touch your /etc/hosts or your certificate CA.
version: '3'
services:
traefik:
restart: unless-stopped
image: traefik:v2.0.2
ports:
- "80:80"
- "443:443"
labels:
- "traefik.http.services.traefik.loadbalancer.server.port=8080"
@thephez
thephez / json-rpc-oas-example.json
Created December 4, 2018 17:33
Example of describing JSON-RPC 2.0 API with OpenAPI
{
"x-send-defaults": true,
"openapi": "3.0.0",
"x-api-id": "json-rpc-example",
"info": {
"title": "JSON-RPC OpenAPI",
"version": "1.0.0",
"description": "Example of how to describe a JSON-RPC 2 API in OpenAPI"
},
"servers": [

Fix for FOUC :

At the top of your HTML:

<!doctype html>
<html>
<head>
    <style>html{visibility: hidden;opacity:0;}</style>
@mrmartineau
mrmartineau / stimulus.md
Last active September 24, 2024 21:07
Stimulus cheatsheet
@tabula-rasa
tabula-rasa / app.scss
Created February 24, 2018 20:04
Mithril JS toaster-like notifications with proper css fade-out/fade-in animation
.m-notifications {
position: fixed;
bottom: 20px;
right: 20px;
display: flex;
flex-direction: column;
align-items: flex-end;
z-index: 10;
.m-notification {
//https://stackoverflow.com/questions/1179672/how-to-avoid-installing-unlimited-strength-jce-policy-files-when-deploying-an
private static void removeCryptographyRestrictions() {
if (!isRestrictedCryptography()) {
return;
}
try {
/*
* Do the following, but with reflection to bypass access checks:
*
* JceSecurity.isRestricted = false; JceSecurity.defaultPolicy.perms.clear();
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active November 16, 2024 16:15
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example