Skip to content

Instantly share code, notes, and snippets.

View lee2sman's full-sized avatar

Lee T lee2sman

  • W/O/R/L/D/W/I/D/E
View GitHub Profile
@lee2sman
lee2sman / pdfmerge
Created September 20, 2016 08:55
commandline tool to batch combine pdf files in current directory, using ghostscript
#!/bin/bash
#
# PDF Combiner
# Combines all files ending in .pdf in current directory
# cc0 Lee2sman 2016
#
# DEPENDENCIES: gs
# USAGE: ./pdfmerge output.pdf
# Make executable and put this in your PATH to be able to run it with pdfmerge output.pdf
@lee2sman
lee2sman / JoystickButton.ino
Last active November 18, 2016 23:24
for use in GameLab to translate joystick/button presses to keypresses via Arduino Leonardo
// Reads arduino digital pins and maps them to USB Joystick library
// NOTE: This sketch file is for use with Arduino Leonardo and Arduino Micro only.
// MODIFIED by Lee2sman 2016-11-18
// REQUIRES ArduinoJoystickLibrary by Matthew Heironimus
// Download at https://github.com/MHeironimus/ArduinoJoystickLibrary/tree/version-1.0
// This uses the Joystick (not Joystick2 or Joystick3) library. Unzip, drop it in your arduino / libraries folder
// Then flash to your Leonardo or Micro board. Use Enjoy2 (Mac) or Joy2Key (PC) to map it to button presses for a game.
// --------------------------------------------------------------------
#include <Joystick.h>
@lee2sman
lee2sman / reset_Kangaroo_Computers.md
Created March 20, 2017 20:56
Use this if you need to eliminate a previous user/admin and reset from zero.

How To Reset Kangaroo Computers

  1. Plug in Kangaroo computer plus usb keyboard, mouse and power
  2. Turn it on (holding in power button)
  3. After computer starts, click the Power button in the bottom right. Hold down SHIFT button and choose Restart. Keep finger on shift until you get to the "Choose An Option" Screen.
  4. Click Troubleshoot
  5. Choose Reset This PC
  6. Choose Remove Everything
  7. Wait for computer to run through "Preparing." This takes 2 minutes.
@lee2sman
lee2sman / jekyll-post-page.md
Created May 2, 2017 07:40 — forked from michaellee/jekyll-post-page.md
Jekyll 101: Creating a new post and page

One of the features that made me fall in love with Jekyll was how super simple it was to start a new project. With one command jekyll new project_name you've got a brand new Jekyll project to start working on.

Posts

If your new Jekyll project is going to be used for blogging, you'll want to create posts for your new blog.

Jekyll by default provides a folder in which all your posts live. Within the Jekyll project, you'll find a folder called _posts. To create a new post you'll need to create a new markdown file with a file name in this format:

YYYY-MM-DD-title.markdown
@lee2sman
lee2sman / rogueready.fish
Created May 27, 2017 21:57
Sets up screen for roguelikes on PocketCHIP / tiny screen
# Use on PocketCHIP computer for Roguelikes (and other curses apps that may need it)
# resizes text rows/columns and fontsize
echo "Readying Rogue...Type exit after quitting to return to terminal"
sleep 2
urxvt +sb -b 0 -w 0 -fn 6x10
# if not installed, sudo apt-get install rxvt-unicode
# this removes scrollbars from side and changes font size
@lee2sman
lee2sman / flow_music.md
Last active February 19, 2024 23:46
Music for working, writing, editing, concentration and flow states.
@lee2sman
lee2sman / fix_imageCapture.sh
Created June 16, 2017 01:11
Fixes issue where Image Capture can't unlock / download photos from iphone. Trashes prefs.
# This is really a bookmark for myself since I need to do this every 6 months and always forget what to do
rm ~/Library/Preferences/com.apple.Image_Capture.plist
@lee2sman
lee2sman / nosleep.sh
Created July 22, 2017 02:15
Use to keep ChipOS from going to sleep
# Forces ChipOS to stay on (no sleep)
# Particularly useful when running Piratebox to keep from turning off when screen sleeps
# Don't forget to sudo chmod +x nosleep.sh
# to run at startup, add this to end of .bashrc
# path/to/nosleep.sh &
# might need to force terminal at start instead of gui
export XAUTHORITY=/home/chip/.Xauthority
export DISPLAY=:0
xset s off
@lee2sman
lee2sman / bash_cheatsheet.md
Last active June 23, 2022 16:35
bash scripting cheatsheet

Bash scripting cheatsheet

  • by Lee2sman
  • Updated 2017-09-18

Bash shebang

  • #!/usr/bin/env bash for portability, or less good, #!/bin/bash

Commenting

@lee2sman
lee2sman / Readings_on_Open_Source.md
Last active June 30, 2022 17:38
Entry Readings on open source, free software and hacker culture

Introductory readings for students on Open Source, Free Software and Hacker culture

Crowdsourced Non-Comprehensive List developed in response to a Facebook query by https://github.com/jeffthompson

Text suggestions from Michael Mandiberg, Allison Parrish, Jeff Thompson, GS Voss, Sterling Crispin, Lee Tusman, Lainie Fefferman, Michael Gubbels. Additional readings and suggestions, especially for perspectives from women and POC welcomed.