Skip to content

Instantly share code, notes, and snippets.

@lukas-h
lukas-h / license-badges.md
Last active May 21, 2024 17:21
Markdown License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • The badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.

Translations: (No guarantee that the translations are up-to-date)

@egmontkob
egmontkob / Hyperlinks_in_Terminal_Emulators.md
Last active May 21, 2024 17:20
Hyperlinks in Terminal Emulators
@mrk-han
mrk-han / change-accessibility-settings-with-adb.md
Last active May 21, 2024 17:20
Enable and Disable Android Accessibility Settings from the Command Line using ADB (Font scale, talkback, color blind)

Using ADB to control Accessbility settings for easier testing with Android Emulators + Real Devices

It's a lot easier to test accessibility on the fly using ADB. This gist attempts to make the days of navigating through the Android device settings UI to change Accessibility settings obsolete.

These ADB commands will hopefully encourage Android developers to test and use their apps with common Accessiblility settings enabled.

Credit to James Nitsch for inspiring this, and for figuring out the put commands to enable these settings.

Font Scale (Font Size -- Testing Dynamic Text)

@drnic
drnic / Hello.tsx
Created June 15, 2023 23:37
In Rails apps using StimulusJS, load React components found at app/javascript/react/*/index.tsx, and make them available via Ruby helper react(name)
import React from "react";
const Hello = ({ name }: { name: string }) => <span>Hello {name}</span>;
Hello.defaultProps = { name: "World" }
export default Hello;
@joelthompson
joelthompson / README.md
Last active May 21, 2024 17:19
Vault Auth
@ohmantics
ohmantics / hb-setup.sh
Last active May 21, 2024 17:17
Homebridge in an iocage jail
DATASET=/zroot/apps
# Create the jail
iocage create -n "homebridge" -r 13.1-RELEASE dhcp=1 bpf=1 vnet=1 allow_raw_sockets="1" boot="on"
# switch to Latest
iocage exec homebridge "mkdir -p /usr/local/etc/pkg/repos"
iocage exec homebridge "echo -e 'FreeBSD: { url: \"pkg+http://pkg.FreeBSD.org/\${ABI}/latest\" }' > /usr/local/etc/pkg/repos/FreeBSD.conf"
# Install Homebridge and dependencies
@Jonalogy
Jonalogy / handling_multiple_github_accounts.md
Last active May 21, 2024 17:16
Handling Multiple Github Accounts on MacOS

Handling Multiple Github Accounts on MacOS

The only way I've succeeded so far is to employ SSH.

Assuming you are new to this like me, first I'd like to share with you that your Mac has a SSH config file in a .ssh directory. The config file is where you draw relations of your SSH keys to each GitHub (or Bitbucket) account, and all your SSH keys generated are saved into .ssh directory by default. You can navigate to it by running cd ~/.ssh within your terminal, open the config file with any editor, and it should look something like this:

Host *
 AddKeysToAgent yes

> UseKeyChain yes

@FbN
FbN / vite.config.js
Last active May 21, 2024 17:16
vite.config.js node built-in polyfills
// yarn add --dev @esbuild-plugins/node-globals-polyfill
import { NodeGlobalsPolyfillPlugin } from '@esbuild-plugins/node-globals-polyfill'
// yarn add --dev @esbuild-plugins/node-modules-polyfill
import { NodeModulesPolyfillPlugin } from '@esbuild-plugins/node-modules-polyfill'
// You don't need to add this to deps, it's included by @esbuild-plugins/node-modules-polyfill
import rollupNodePolyFill from 'rollup-plugin-node-polyfills'
export default {
resolve: {
alias: {
@realvjy
realvjy / ChoasLinesShader.metal
Last active May 21, 2024 17:14
Choas Lines - Metal Shader
// Lines
float hash( float n ) {
return fract(sin(n)*753.5453123);
}
// Slight modification of iq's noise function.
float noise(vector_float2 x )
{
vector_float2 p = floor(x);
vector_float2 f = fract(x);
@wallyhall
wallyhall / apache_airflow_sso_howto.md
Last active May 21, 2024 17:14
Apache Airflow Azure AAD SSO howto

The following instructions for enabling Azure SSO for Apache Airflow nearly take you all the way - but fall short a couple of details around the configuration of airflow itself:

https://objectpartners.com/2021/12/24/enterprise-auth-for-airflow-azure-ad

All the "Azure" instructions there can be safely followed - the resulting webserver_config.py (which can be injected into a dockerised Airflow in /opt/airflow/webserver_config.py) can be built from the following:

from __future__ import annotations

import os