Skip to content

Instantly share code, notes, and snippets.

View TangentFoxy's full-sized avatar

Rose Liverman TangentFoxy

View GitHub Profile
@TangentFoxy
TangentFoxy / mov2mp4.ps1
Created September 22, 2017 00:37
Simple Powershell script to use ffmpeg to convert an MOV file to an MP4 file.
$input = $args[0]
$output = $input.Replace(".MOV", ".mp4")
$output = $output.Replace(".mov", ".mp4") # in case ext is lowercase
ffmpeg -i "$input" -vcodec copy -acodec copy "$output"
@TangentFoxy
TangentFoxy / Persist History.ps1
Created September 7, 2017 04:42
Making PowerShell history persist between sessions.
# Usage: run this file, it will install itself
# to $profile and be run from there
# Make sure $profile exists.
if (! (Test-Path $profile) ) {
New-Item -Path $profile -ItemType File -Force
}
# Find ourselves and where we should be.
$me = $PSCommandPath # $MyInvocation.MyCommand.Definition
@TangentFoxy
TangentFoxy / Class.lua
Last active December 9, 2017 17:29
MoonScript-compatible class function for Lua.
-- This is an implementation of classes compatible with MoonScript's classes.
-- CC0 license
-- Usage:
-- local Class = require "Class"
-- local SomeClass, BaseObject = Class("NameOfClass")
-- define your own init:
-- function SomeClass:__init() end
@TangentFoxy
TangentFoxy / identity.md
Created September 10, 2016 03:17
Keybase proof.

Keybase proof

I hereby claim:

  • I am Guard13007 on github.
  • I am guard13007 (https://keybase.io/guard13007) on keybase.
  • I have a public key whose fingerprint is 1A74 AE9E 1AFC 020C CBFE 5A8E 8CD5 45C0 0785 7098

To claim this, I am signing this object:

@TangentFoxy
TangentFoxy / Starfield.lua
Created June 19, 2016 02:36
Original Starfield generator. It takes a random and very long amount of time to determine an appropriate Starfield, but is more adjustable than the version I am using.
local Starfield = {}
Starfield.__index = Starfield
--NOTE TEMP FOR STATS
local results = {}
function Starfield:clipResults()
local str = "count,threshold,ox,oy\n"
for i = 1, #results, 4 do
str = str .. results[i] .. "," .. results[i+1] .. "," .. results[i+2] .. "," .. results[i+3] .. "\n"