Skip to content

Instantly share code, notes, and snippets.

View rsheldiii's full-sized avatar

Bob rsheldiii

View GitHub Profile
@rsheldiii
rsheldiii / LICENSE.txt
Last active May 18, 2024 03:02
transfer your Zune favorites over to Youtube Music
MIT License
Copyright (c) [year] [fullname]
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:
@rsheldiii
rsheldiii / johnstewart.rb
Created July 6, 2022 21:04
John Stewart raspberry pi service
# /home/pi/johnstewart.rb
require 'pp'
# monke
class String
def naturalized
scan(/[^\d\.]+|[\d\.]+/).collect { |f| f.match(/\d+(\.\d+)?/) ? f.to_f : f }
end
end
@rsheldiii
rsheldiii / .pythonstartup.py
Last active June 29, 2022 22:17
Use exit and quit instead of exit() and quit() in the cPython REPL
exit.__class__.__repr__ = lambda self: self.__call__()
@rsheldiii
rsheldiii / config.json
Created April 24, 2022 19:03
Monogram creator VLC Node client
{
"name": "YourAppNameHere",
"id": "com.example.your_app_name_here",
"exe": ["vlc.exe"],
"bundle": ["com.example.your_app_name_here"],
"connection": [
{
"name": "YourConnectionNameHereConnection",
"type": "websocket"
}
@rsheldiii
rsheldiii / patch.patch
Created April 6, 2019 19:06
Gherkin combo patch
diff --git a/keyboards/40percentclub/gherkin/config.h b/keyboards/40percentclub/gherkin/config.h
index d0c2be35b..b541e073a 100644
--- a/keyboards/40percentclub/gherkin/config.h
+++ b/keyboards/40percentclub/gherkin/config.h
@@ -37,6 +37,9 @@
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
+#define COMBO_COUNT 2
+#define COMBO_TERM 200
@rsheldiii
rsheldiii / keymap.c
Created February 22, 2019 21:41
Gergo keymap
/* Good on you for modifying your layout! if you don't have
* time to read the QMK docs, a list of keycodes can be found at
*
* https://github.com/qmk/qmk_firmware/blob/master/docs/keycodes.md
*
* There's also a template for adding new layers at the bottom of this file!
*/
#include QMK_KEYBOARD_H
@rsheldiii
rsheldiii / keymap.c
Last active January 25, 2019 17:02
Gherkin keymap.c with combos
/* Copyright 2017 Brian Fong
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@rsheldiii
rsheldiii / ConstantsContext.jsx
Created January 14, 2019 17:05
React Higher Order Component to manage constants on the context
import React, { Component } from 'react';
import PropTypes from 'prop-types';
const ConstantContext = React.createContext({});
const ConstantConsumer = ConstantContext.Consumer;
export const ConstantProvider = ConstantContext.Provider;
export const ConstantConnect = (Wrappee) => {
@rsheldiii
rsheldiii / sandwich.rb
Created October 6, 2016 19:00
automatic compliment sandwich generator
#!/usr/bin/env ruby
top = ['this looks awesome! ', 'this is excellent!', 'My eyes, they can\'t handle the glory!', 'but soft! what code through yonder window breaks?', 'Stellar!', 'Radical dude!', 'Perfect! I love it!']
bottom = ['You got it, dude!', 'keep rockin, pal!', 'But that\'s just a small suggestion.', 'But everything else is wonderful!', 'But I love how everything else looks!']
puts [top.sample, ARGV.join(' '), bottom.sample].join(' ')
@rsheldiii
rsheldiii / twitchitup.sh
Created September 20, 2016 03:33
Watch twitch screens on a framebuffer on a raspberry pi with mplayer2
#!/usr/bin/bash
# after running whichever modprobe fbtft_device command
sudo SDL_VIDEODRIVER=fbcon SDL_FBDEV=/dev/fb1 livestreamer twitch.tv/$1 mobile --yes-run-as-root -v -p 'mplayer --nosound --noass --no-autosub --no-lirc --no-mouseinput --no-mouseinput -vo sdl'