Skip to content

Instantly share code, notes, and snippets.

Bradley Walters bmwalters

Block or report user

Report or block bmwalters

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@bmwalters
bmwalters / _Solarized.terminal
Created Sep 26, 2019
my Terminal.app configuration
View _Solarized.terminal
<?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>ANSIBlackColor</key>
<data>
YnBsaXN0MDDUAQIDBAUGIiNYJHZlcnNpb25YJG9iamVjdHNZJGFyY2hpdmVyVCR0b3AS
AAGGoKYHCBMXGB9VJG51bGzVCQoLDA0ODxARElxOU0NvbXBvbmVudHNVTlNSR0JcTlND
b2xvclNwYWNlXxASTlNDdXN0b21Db2xvclNwYWNlViRjbGFzc08QJzAuMjMxMzcyNTQ5
IDAuMjU4ODIzNTI5NCAwLjMxNzY0NzA1ODggMU8QJzAuMTc1MzU2OTg0MSAwLjE5NTk5
@bmwalters
bmwalters / PKGBUILD
Last active Nov 20, 2018
Arch PKGBUILD for Vittorio Romeo's OpenHexagon / SSVOpenHexagon
View PKGBUILD
# Maintainer: Bradley Walters <oss@walters.app>
pkgname=openhexagon-git
pkgver=r1733.4791b23
pkgrel=1
pkgdesc='C++14 FOSS clone of "Super Hexagon"'
arch=('i686' 'x86_64' 'armv6h') # TODO: check these
url="https://vittorioromeo.info/projects.html"
license=('custom:AFL-3.0')
depends=('sfml' 'lua')
View resreader.py
#!/usr/bin/env python3
import os
import xml.etree.ElementTree as ElementTree
tree = ElementTree.parse("Resources.resx")
datas = sorted(map(lambda x: (x, len(x.find("value").text)), tree.getroot().findall("data")), key=lambda x: x[1])
if not os.path.isdir("Split_out/"):
@bmwalters
bmwalters / vimeofixer.user.js
Last active Dec 31, 2017
Re-enable the context menu on videos in the Vimeo embedded player
View vimeofixer.user.js
// ==UserScript==
// @name Vimeo Embed Playback Rate Control
// @namespace zerf
// @match *://player.vimeo.com/*
// @grant none
// @run-at document-end
// ==/UserScript==
const log = (...args) => console.log("[ZERFVIMEO]", ...args)
@bmwalters
bmwalters / README.md
Last active Oct 26, 2018
Hopper solus package
View README.md

Hopper Disassembler package for Solus

This is a package for eopkg for the Hopper Disassembler.

Installation

sudo eopkg bi https://gist.githubusercontent.com/bmwalters/d453feb913492c23df06d78820fee4d7/raw/pspec.xml
sudo eopkg it hopper-disassembler-*.eopkg;sudo rm hopper-disassembler-*.eopkg
@bmwalters
bmwalters / hoax.lua
Last active Feb 14, 2017
ES2015 Promises implemented in Lua 5.3
View hoax.lua
local function check_callable(o)
return type(o) == "function" or type(getmetatable(o).__call) == "function"
end
local PromiseState = {
pending = "pending",
fulfilled = "fulfilled",
rejected = "rejected"
}
@bmwalters
bmwalters / npmify.lua
Created Jan 8, 2017
Load Lua modules from the node_modules folder!
View npmify.lua
local string = require("string")
local pathlib = require("pl.path")
local filelib = require("pl.file")
local function split(str, sep)
local ret = {}
local last_sep = 1
for i = 1, #str do
if string.byte(str, i, i) == string.byte(sep) then
View simple_version.py
class SimpleVersion():
def __init__(self, major, minor, patch):
self.major = major
self.minor = minor
self.patch = patch
@classmethod
def fromstring(c, version_str):
split = [int(x or "0") for x in version_str.split(".")]
@bmwalters
bmwalters / multimc_install_optifine.py
Last active Nov 22, 2017
Automatically install OptiFine to a MultiMC instance
View multimc_install_optifine.py
#!/usr/bin/env python3
import cfscrape # install with `pip install cfscrape`
import re
import os
import json
from packaging.version import Version
def build_multimc_patch_json(mc_version, optifine_version):
patch = {
You can’t perform that action at this time.