Skip to content

Instantly share code, notes, and snippets.

View cymen's full-sized avatar

Cymen Vig cymen

  • Vig Consulting, LLC
  • Remote
View GitHub Profile
@cymen
cymen / sierrakeygen.py
Created June 29, 2022 02:22 — forked from jkinred/sierrakeygen.py
Sierra Keygen
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# (c) B.Kerler 2019 under MIT license
# If you use my code, make sure you refer to my name
# If you want to use in a commercial product, ask me before integrating it
import serial
import sys
import argparse
from binascii import hexlify, unhexlify
<%
# Build the helper file
# assumes config.assets.paths << Rails.root.join('tmp', 'teaspoon', 'assets') in development.rb
tmp_assets = Rails.root.join("tmp/teaspoon/assets")
spec_helper = File.join(tmp_assets, "spec_helper.js")
FileUtils.mkdir_p(File.dirname(spec_helper)) unless File.directory?(File.dirname(spec_helper))
specs = @suite.spec_assets(false).map{ |s| "#{s.gsub(/\.js.*$/, "")}" }
@cymen
cymen / example_spec.js.coffee
Created October 11, 2012 21:19 — forked from jfirebaugh/example_spec.js.coffee
Auto-restoring sinon fakes with Konacha
# require spec_helper
Test =
fn: -> 'result'
it 'auto-resets sinon fakes', ->
@stub(Test, 'fn')
Test.fn()
Test.fn.should.have.been.called
@cymen
cymen / 0-readme.md
Created April 15, 2012 04:48
ruby-1.9.3-p125 cumulative performance patch.

Patched ruby 1.9.3-p125 for 30% faster rails boot

What is?

This script installs a patched version of ruby 1.9.3-p125 with patches to make ruby-debug work again (#47) and boot-time performance improvements (#66 and #68), and runtime performance improvements (#83 and #84). It also includes the new backported GC from ruby-trunk.

Huge thanks to funny-falcon for the performance patches.

@cymen
cymen / gist:1282505
Created October 12, 2011 20:51 — forked from saikat/gist:1084146
Stripe sample checkout form
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>Stripe Sample Form</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>
<script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js"></script>
<script type="text/javascript" src="https://js.stripe.com/v1/"></script>
<script type="text/javascript">