Skip to content

Instantly share code, notes, and snippets.

using System;
using System.Collections.Generic;
using System.Linq;
namespace PSMay.Experiments.MoreZipGist
{
// NB: This is a work in progress. It's not fully tested, but it might be good for an idea or two.
//
// To the extent possible under law, the author(s) have dedicated all copyright and related and
// neighboring rights to this software to the public domain worldwide.This software is
@psmay
psmay / mpmd-magnetic-clip-mod.stl
Last active February 28, 2021 21:33
MPMD Magnetic Bed Clip with separate two-piece anchor (Loosely based on https://www.thingiverse.com/thing:3412636 by ksihota, CC-BY 4.0.) See comments.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@psmay
psmay / mpmd-magnetic-clip.scad
Last active January 28, 2021 19:04
MPMD Magnetic Bed Clip plus way too many parameters
/*
MPMD Magnetic Bed Clip plus way too many parameters
Copyright © 2021 Peter S. May
Based on MPMD adjustable magnetic bed clip v6 by ksihota
https://www.thingiverse.com/thing:3412636
Licensed under Creative Commons - Attribution 4.0
@psmay
psmay / Program.cs
Last active March 8, 2020 23:06
For ConfigurationBuilder.AddInMemoryCollection(), one possibility for utilizing arbitrary <string, object> mappings
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Newtonsoft.Json;
namespace AddingStringObjectDictionaryToConfiguration
@psmay
psmay / renonce-fritzing-part.sh
Last active August 2, 2016 20:26
Script that unpacks Fritzing part fzpz files and replaces their 128-bit hex nonce with one newly generated by uuidgen. Useful for preventing name collisions when creating a modified copy of an existing part.
FZPZ="$1"
die () {
echo "$1" >&2
exit 2
}
die_if_blank () {
Early prototype Arduino sketch for bidi SextetStream I/O
Copyright (c) 2015 Peter S. May
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:
@psmay
psmay / schedule.sh
Last active August 29, 2015 14:10
Get a list of scripts in a dir and allow them to order themselves using a "#require " line stating deps.
BASHRC_D=~/.bashrc.d
schedule()
{
(
while [ $# -gt 0 ]; do
local name="$1"
(
case "$name" in
@psmay
psmay / svg-to-fontforge-python.md
Created December 2, 2014 15:14
Notes on mass-importing SVG outlines into FontForge via Python

Notes on dumping SVG outlines into a FontForge file

Sources I've looked at:

I have a hunch that createMappedChar() doesn't work unless you've done loadNameList('glyphlist.txt') or loadNameList('aglfn.txt') (BSD-licensed Adobe glyph lists). An alternative seems to be to go by codepoint with createChar().

@psmay
psmay / subdir-repo-bridge.sh
Created November 21, 2014 15:08
Crude subdir to repository bridge
#!/bin/bash
# For our convenience since this is repeated
github_user="someuser"
our_label="loose-repo-name"
# Our local clone of the parent repo will be configured as a sparse checkout
# to check out only the specified subdir
parent_url=https://github.com/somebody/something.git
parent_branch=master

StepMania default theme

psmay/stepmania-default-theme is a repo to track only the Themes/default directory within the stepmania project. The goal is to be able to fork the repo, create a new default-based theme, and then be able to observe the relative changes made and merge in improvements made to default as they are added.

How to use

  • Fork the repo.
  • GitHub can only automatically fork a given repository once. If you want to maintain more than one theme based on this repo, you can still fork manually (see below).