Skip to content

Instantly share code, notes, and snippets.

### Keybase proof
I hereby claim:
* I am mikezter on github.
* I am mikezter (https://keybase.io/mikezter) on keybase.
* I have a public key whose fingerprint is F0B9 2EEA 086C 43D5 F894 B4AF 70EA 19A2 7908 F63A
To claim this, I am signing this object:
@mikezter
mikezter / transact.rb
Created February 12, 2016 02:14
script using bx libbitcoin-explorer to create a transaction ready to send to the bitcoin network
#!/usr/bin/env ruby
require 'json'
require 'active_support/core_ext/hash/conversions'
# BX libbitcoin-explorer
SRC_ADDR=""
DEST_ADDR=""
CHANGE_ADDR=""
@mikezter
mikezter / bfs.go
Created August 24, 2016 20:44
read a buffer, make a tree, calculate distance of all other nodes from start-node
package main
import (
"bytes"
"fmt"
"io"
"os"
)
var sample = []byte(`2
@mikezter
mikezter / microdao.abi
Created June 19, 2017 10:13 — forked from zoernert/microdao.abi
Micro DAO to create an EVU in Germany
[ { "constant": true, "inputs": [], "name": "name", "outputs": [ { "name": "", "type": "string", "value": "MicroDAO" } ], "type": "function" }, { "constant": false, "inputs": [], "name": "executeSpendingRequests", "outputs": [], "type": "function" }, { "constant": false, "inputs": [ { "name": "number_of_days", "type": "uint256" }, { "name": "requiredShares", "type": "uint256" } ], "name": "setDirectorLock", "outputs": [], "type": "function" }, { "constant": true, "inputs": [ { "name": "", "type": "uint256" } ], "name": "bookings", "outputs": [ { "name": "time", "type": "uint256" }, { "name": "funding", "type": "uint256" }, { "name": "spending", "type": "uint256" }, { "name": "counterpart", "type": "address" }, { "name": "text", "type": "string" } ], "type": "function" }, { "constant": false, "inputs": [], "name": "closeFunding", "outputs": [], "type": "function" }, { "constant": false, "inputs": [ { "name": "node", "type": "string" } ], "name": "setDirectorNode", "outputs": [], "type": "function" }, { "consta
pnputil /enum-drivers > ./driveroutput.txt
Get-Content .\driveroutput.txt | Select-String -Pattern "Published Name" | %{$_.Line.Split(" ")} | Select-String -Pattern ".inf" | Where { $_ } | Set-Content .\oems.txt
foreach($line in Get-Content .\oems.txt) {
pnputil.exe /delete-driver $line
}
@mikezter
mikezter / DisplayPercentageM73.py
Last active March 19, 2020 22:33
Custom menu for Klipper firmware on Creality Ender 3
# Author: @mikezter
# Date: 2020-03-18
# Description: This plugin uses Cura TIME and TIME_ELAPSED estimations
# to calculate build percentage and time remaining.
# It can insert M73 P<percentage> and M117 <time remaining> gcodes.
from ..Script import Script
import re
class DisplayPercentageM73(Script):
@mikezter
mikezter / smart-caps-lock.md
Created October 20, 2020 20:21 — forked from tanyuan/smart-caps-lock.md
Smart Caps Lock: Remap Caps Lock to Control AND Escape

Smart Caps Lock: Remap to Control AND Escape (Linux, Mac, Windows)

Caps Lock 變成智慧的 Control 以及 Escape

  • 單獨輕按一下就是 Escape
  • 若按下時同時按著其他鍵,就會是 Control

這應該是 Vim 和 Emacs 的最佳解了!(Emacs? Bash 的快捷鍵就是 Emacs 系列的)

  • Send Escape if you tap Caps Lock alone.
esphome:
name: qs-wifi-ds02-2c
platform: ESP8266
board: esp01_1m
wifi:
ssid: "MyWiFi_SSID"
password: "MyWiFi_pw"
# Enable fallback hotspot (captive portal) in case wifi connection fails
@mikezter
mikezter / cameo.yml
Created April 2, 2022 13:42
esp32 camera settings
substitutions:
dname: cameo
dip: 192.168.0.224
esphome:
name: $dname
esp32:
board: esp32dev
framework: