Skip to content

Instantly share code, notes, and snippets.

View invalidusrname's full-sized avatar
🤷‍♀️

Matt invalidusrname

🤷‍♀️
View GitHub Profile
# $Id: Portfile 64302 2010-03-01 13:30:40Z [email protected] $
PortSystem 1.0
PortGroup archcheck 1.0
name ImageMagick
conflicts cryptlib
version 6.6.0-0
set reasonable_version [lindex [split ${version} -] 0]
homepage http://www.imagemagick.org/
@invalidusrname
invalidusrname / word_export.html
Last active April 3, 2019 20:19
Saving a word document saying nothing more than "test" as html
<html xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml"
xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name=Title content="">
<meta name=Keywords content="">
<meta http-equiv=Content-Type content="text/html; charset=macintosh">
<meta name=ProgId content=Word.Document>
@invalidusrname
invalidusrname / test.html
Last active April 3, 2019 20:53
Textmate HTML Template of "test"
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>untitled</title>
<meta name="generator" content="TextMate http://macromates.com/">
<meta name="author" content="Matt McMahand">
<!-- Date: 2011-07-06 -->
@invalidusrname
invalidusrname / crash.log
Last active April 3, 2019 20:06
rvm-1.9.2-p180 webrick crashlog
Process: ruby [31652]
Path: /Users/mmcmahand/.rvm/rubies/ruby-1.9.2-p180/bin/ruby
Identifier: ruby
Version: ??? (???)
Code Type: X86-64 (Native)
Parent Process: bash [9651]
Date/Time: 2011-07-07 23:40:23.405 -0400
OS Version: Mac OS X 10.6.8 (10K540)
Report Version: 6
@invalidusrname
invalidusrname / debugging.log
Last active April 3, 2019 20:54
annoying malloc webrick error?
=> Booting WEBrick
=> Rails 3.0.9 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
[2011-07-08 09:59:36] INFO WEBrick 1.3.1
[2011-07-08 09:59:36] INFO ruby 1.9.2 (2011-02-18) [x86_64-darwin10.8.0]
[2011-07-08 09:59:36] INFO WEBrick::HTTPServer#start: pid=32475 port=3000
Connected to NewRelic Service at collector-5.newrelic.com:80
@invalidusrname
invalidusrname / ar_weirdness.log
Last active April 3, 2019 20:55
after an action has completed? wtf
Rendered dashboard/index.html.haml within layouts/application (82.2ms)
SQL (0.1ms) BEGIN
AREL (0.2ms) UPDATE `users` SET `current_access_at` = '2011-07-08 14:03:34', `updated_at` = '2011-07-08 14:03:34' WHERE `users`.`id` = 55
SQL (0.3ms) COMMIT
Completed 200 OK in 508ms (Views: 80.5ms | ActiveRecord: 12.8ms)
ruby(32508,0x10a281000) malloc: *** error for object 0x100000000: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug
Abort trap
@invalidusrname
invalidusrname / linecache19.bash
Last active April 3, 2019 20:55
damn you line cache!
Installing linecache19 (0.5.12) /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/installer.rb:163:in `install': linecache19 requires Ruby version >= 1.9.2. (Gem::InstallError)
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/source.rb:101:in `install'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/rubygems_integration.rb:78:in `preserve_paths'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/source.rb:91:in `install'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/installer.rb:58:in `run'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/rubygems_integration.rb:93:in `with_build_args'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/installer.rb:57:in `run'
from /Users/mmcmahand/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.15/lib/bundler/spec_set.rb:12:in `each'
from /Users/mmcmahand/.rv
@invalidusrname
invalidusrname / tmux_256_colors.pl
Last active April 3, 2024 17:56
tmux 256 colors
#!/usr/bin/perl
# displays the 256 colors specified in tmux's "colourNN" way.
# June, 1st 2011 by Yasunori Taniike (@ytaniike).
use strict;
use warnings;
my $prefix_bl = "\x1b[38;5;0;48;5;";
my $prefix_wl = "\x1b[38;5;15;48;5;";
my $suffix = "\x1b[0m";
@invalidusrname
invalidusrname / decoupling_test_suite.md
Last active April 3, 2019 20:09
Avoiding AR in tests #testing
@invalidusrname
invalidusrname / action.rb
Last active April 3, 2019 20:16
import csv active admin
collection_action :import_csv, :method => :post do
if params[:card] && params[:card][:csv]
file = params[:card][:csv]
Card.import_from_csv(file.tempfile)
flash[:notice] = "Cards Imported Successfully!"
else
flash[:error] = "CSV File Needed"
end
redirect_to :action => :index
end