Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View tiffany352's full-sized avatar

Tiffany Bennett tiffany352

View GitHub Profile
local Spring = {} do
Spring.__index = Spring
local pi = math.pi
local exp = math.exp
local sin = math.sin
local cos = math.cos
local sqrt = math.sqrt
function Spring.new(dampingRatio, frequency, position)
@getify
getify / 1.js
Last active July 27, 2023 15:50
demonstrating how to use "nodegit" to modify and read from a local bare git repo
/*
NOTE: This code assumes a bare git repo in ./bare-git/,
which should have at least one text file in its root,
named "greetings.txt".
This code updates the contents of a "greetings.txt"
file, and creates a new file called "greetings-XXX.txt"
(with XXX being a random number). It then creates a new
commit for these changes. Finally, it reads and dumps
the new current contents of the repo, file by file.
;;; haskell-font-lock.el --- Font locking module for Haskell Mode
;; Copyright 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
;; Copyright 1997-1998 Graeme E Moss, and Tommy Thorn
;; Author: 1997-1998 Graeme E Moss <gem@cs.york.ac.uk>
;; 1997-1998 Tommy Thorn <thorn@irisa.fr>
;; 2003 Dave Love <fx@gnu.org>
;; Keywords: faces files Haskell
/*
* robotMaze.js
*
* The blue key is inside a labyrinth, and extracting
* it will not be easy.
*
* It's a good thing that you're a AI expert, or
* we would have to leave empty-handed.
*/