Skip to content

Instantly share code, notes, and snippets.

View DOSputin's full-sized avatar
💀
død

DP DOSputin

💀
død
View GitHub Profile
### Keybase proof
I hereby claim:
* I am dosputin on github.
* I am johannessnilsson (https://keybase.io/johannessnilsson) on keybase.
* I have a public key ASCJqKeLLkAeq9gHVArSnM_M0erlbft6LmqVrNB48XKjXgo
To claim this, I am signing this object:
@DOSputin
DOSputin / gist:f36218b96fada71afe32e54dde14d1b4
Created February 25, 2018 05:46
shader-vertex-terrain-perlin
<script id="shader-vertex-terrain-perlin" type="x-shader/x-vertex">
vec3 mod289(vec3 x)
{
return x - floor(x * (1.0 / 289.0)) * 289.0;
}
vec4 mod289(vec4 x)
{
// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible).
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export.
var FORMAT_ONELINE = 'One-line';
var FORMAT_MULTILINE = 'Multi-line';
var FORMAT_PRETTY = 'Pretty';
var LANGUAGE_JS = 'JavaScript';
var LANGUAGE_PYTHON = 'Python';
@DOSputin
DOSputin / cli-deb-install.sh
Created April 18, 2018 23:25
CLI deb installs
TEMP_DEB="$(mktemp)" &&
wget -O "$TEMP_DEB" 'http://path.to/my.deb' &&
sudo dpkg -i "$TEMP_DEB"
rm -f "$TEMP_DEB"
@DOSputin
DOSputin / README.md
Last active January 11, 2019 09:15
A Modified Mac OS Slack Client Dark Theme with Support for Syntax Highlighting

A Modified Mac OS Slack Client Dark Theme with Support for Syntax Highlighting

This must be installed in /Applications/Slack.app/Contents/Resources/app.asar.unpacked/src/static/ssb-interop.js use the editor of your choice to replace the contents of ssb-interop.js with the code below.

I use Sublime Text, and called it from CLI via;

sudo subl /Applications/Slack.app/Contents/Resources/app.asar.unpacked/src/static/ssb-interop.js

Note: it's a very good idea to make a back up copy of ssb-interop.js before making these modifications.

@DOSputin
DOSputin / README.md
Last active September 18, 2018 14:05
minipro winbond

run:

minipro -p "ICE27C512 @DIP28" -w _filename.bin_
@DOSputin
DOSputin / m3u8_ffmpeg_download.MD
Created July 27, 2018 09:48
use ffmpeg to stream chunked video from online .m3u8 playlists to a .mkv cage file.

ffmpeg -i http://...m3u8 -c copy live.mkv

@DOSputin
DOSputin / README.MD
Last active April 14, 2021 07:14
Disable facetime HD cameral Mac OS

Turn Off Rootless System Integrity Protection:

$ csrutil disable

Disable Camera:

all commands performaed as sudo

$ chmod a-r /System/Library/Frameworks/CoreMediaIO.framework/Versions/A/Resources/VDC.plugin/Contents/MacOS/VDC

@DOSputin
DOSputin / README.MD
Created August 9, 2018 04:44
Recursive dot_clean

force Apple's dot_clean util to clean recursivly

$find . -type d | xargs dot_clean -m

@DOSputin
DOSputin / etenv.bitbar.gitlab_ci.plist
Created September 19, 2018 18:51
Set gitlab private token in env
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>setenv.bitbar.gitlab_CI</string>
<key>ProgramArguments</key>
<array>
<string>/bin/launchctl</string>
<string>setenv</string>