Skip to content

Instantly share code, notes, and snippets.

@bradley219
bradley219 / .gitignore
Last active March 25, 2024 15:53
PID C++ implementation
.DS_Store
@wandernauta
wandernauta / sp
Last active March 1, 2024 15:37
sp is a command-line client for Spotify's dbus interface. Play, pause, skip and search tracks from the comfort of your command line.
#!/usr/bin/env bash
#
# This is sp, the command-line Spotify controller. It talks to a running
# instance of the Spotify Linux client over dbus, providing an interface not
# unlike mpc.
#
# Put differently, it allows you to control Spotify without leaving the comfort
# of your command line, and without a custom client or Premium subscription.
#
@jeroenvollenbrock
jeroenvollenbrock / aws-cloudfront-basic-auth.js
Last active July 20, 2023 20:18
AWS-CloudFront-basic-auth
var USERS = {
protecteddir: [{
username: 'user',
password: 'pass',
}],
};
//Response when auth is not valid.
var response401 = {
statusCode: 401,
@show0k
show0k / install_git_lfs.sh
Last active March 5, 2019 18:35
Compile and Install git-lfs on Raspberry Pi (with golang compilation)
install_git_lfs()
{
set -e
# Get out if git-lfs is already installed
if $(git-lfs &> /dev/null); then
echo "git-lfs is already installed"
return
fi
GIT_LFS_BUILD=$HOME/.bin
@m93a
m93a / bash.bat
Created November 7, 2017 10:18
Enable bash.exe for 32-bit programs
@echo off
rem To use bash seamlessly from 32bit apps,
rem add this file to your %PATH%.
if exist C:\Windows\Sysnative\bash.exe (
start "bash.exe" /D "%cd%" /B /wait "C:\Windows\Sysnative\bash.exe" %*
) else (
start "bash.exe" /D "%cd%" /B /wait "C:\Windows\System32\bash.exe" %*
)