Skip to content

Instantly share code, notes, and snippets.

View bmishkin's full-sized avatar
🎯
Focusing

Ben Mishkin bmishkin

🎯
Focusing
  • Anthem.AI
  • Austin, TX
View GitHub Profile

Keybase proof

I hereby claim:

  • I am bmishkin on github.
  • I am bmishkin (https://keybase.io/bmishkin) on keybase.
  • I have a public key ASBOxj1j-fmBPN3K3155ZYvhyarH4te8XaN5mTCZ6ZwDugo

To claim this, I am signing this object:

@bmishkin
bmishkin / sphinx.rb
Last active December 20, 2015 23:09
Mac homebrew Sphinx 0.9.9 formula for mysql. REQUIRES '--use-llvm'
require 'formula'
class Libstemmer < Formula
# upstream is constantly changing the tarball,
# so doing checksum verification here would require
# constant, rapid updates to this formula.
head 'http://snowball.tartarus.org/dist/libstemmer_c.tgz'
homepage 'http://snowball.tartarus.org/'
end
@bmishkin
bmishkin / gist:1304068
Created October 21, 2011 15:03
position-fix migration run
hobbes-imac:trs_trunk $ rake db:migrate
(in /Volumes/Calvin/Users/bmishkin/develop/trs_trunk)
== FixActivityGroupPositions: migrating ======================================
Saving ActivityGroup 32 for event 2005 Multiple Sclerosis Turkey Trot, position 1
Saving ActivityGroup 54 for event Greater Louisville CVB Business After Hours, position 1
Saving ActivityGroup 55 for event Greater Louisville CVB Business After Hours, position 2
Saving ActivityGroup 125 for event Another test event, position 1
Saving ActivityGroup 126 for event Another test event, position 2
Saving ActivityGroup 1284 for event 2009 Heartland Truly Moving Pictures, position 24
Saving ActivityGroup 4212 for event 2011 Grace Community Church Weekend of Service Team Leaders, position 5
@bmishkin
bmishkin / gist:1304059
Created October 21, 2011 15:01
trs: invalid activity groups
hobbes-imac:trs_trunk $ rake validate:classes classes="ActivityGroup"
(in /Volumes/Calvin/Users/bmishkin/develop/trs_trunk)
Validating: ActivityGroup
*** Checking ActivityGroup
ActivityGroup:32:#<ActiveRecord::Errors:0x10c9a52b0 @errors={"position"=>["has already been taken"]}, @base=#<ActivityGroup id: 32, event_id: 20, position: 0, view_type_id: 1, name: "MS Turkey Trot", is_default: false, visible: true, show_cost: true, sort_activities_by_date: false, min_selection: nil, max_selection: nil, created_at: "2005-09-27 14:52:58", updated_at: "2007-04-27 08:25:39", description: "MS Turkey Trot", private: false>>
ActivityGroup:33:#<ActiveRecord::Errors:0x10c991850 @errors={"position"=>["has already been taken"]}, @base=#<ActivityGroup id: 33, event_id: 20, position: 0, view_type_id: 1, name: "Donation", is_default: false, visible: true, show_cost: true, sort_activities_by_date: false, min_selection: nil, max_selection: nil, created_at: "2005-09-29 13:57:02", updated_at: "2007-04-27 08:25:39", description: "Donat
@bmishkin
bmishkin / gist:1301377
Created October 20, 2011 15:05
countrystone cukes
Last login: Thu Oct 20 10:34:56 on ttys005
Hobbes-iMac:~ $ cd develop/countrystone/
Hobbes-iMac:countrystone $ git status
# On branch master
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: app/models/formula.rb
# modified: app/models/ingredient.rb
@bmishkin
bmishkin / gist:1301342
Created October 20, 2011 14:52
countrystone validations (all except sales order, plantinventoryitem
Hobbes-iMac:countrystone $ rake db:validate skip_classes="sales_order, plant_inventory_item"
WARNING: Global access to Rake DSL methods is deprecated. Please include
... Rake::DSL into classes and modules which use the Rake DSL methods.
WARNING: DSL method Cucumber::Rake::Task#desc called at /Users/bmishkin/.rvm/gems/ruby-1.9.2-p136@rails3-countrystone-erp/gems/cucumber-0.10.0/lib/cucumber/rake/task.rb:140:in `define_task'
WARNING: DSL method Cucumber::Rake::Task#task called at /Users/bmishkin/.rvm/gems/ruby-1.9.2-p136@rails3-countrystone-erp/gems/cucumber-0.10.0/lib/cucumber/rake/task.rb:141:in `define_task'
WARNING: Global access to Rake DSL methods is deprecated. Please include
... Rake::DSL into classes and modules which use the Rake DSL methods.
WARNING: DSL method Cucumber::Rake::Task#desc called at /Users/bmishkin/.rvm/gems/ruby-1.9.2-p136@rails3-countrystone-erp/gems/cucumber-0.10.0/lib/cucumber/rake/task.rb:140:in `define_task'
WARNING: DSL method Cucumber::Rake::Task#task called at /User
@bmishkin
bmishkin / gist:1301301
Created October 20, 2011 14:33
country stone production-related validations
Hobbes-iMac:countrystone $ rake db:validate classes="inventory_item, formula, ingredient, bill_of_material, inventory_production, packaging, inventory_item_packaging"
Validating: InventoryItem, Formula, Ingredient, BillOfMaterial, InventoryProduction, Packaging, InventoryItemPackaging
*** Checking InventoryItem
InventoryItem:2199:{:volume_in_quarts=>["must be greater than 0"]}
InventoryItem:2200:{:weight_in_pounds=>["must be greater than 0"], :volume_in_quarts=>["must be greater than 0"]}
InventoryItem:2201:{:weight_in_pounds=>["must be greater than 0"], :volume_in_quarts=>["must be greater than 0"]}
InventoryItem:2202:{:volume_in_quarts=>["must be greater than 0"]}
InventoryItem:2238:{:weight_in_pounds=>["must be greater than 0"]}
InventoryItem:2241:{:weight_in_pounds=>["must be greater than 0"]}
@bmishkin
bmishkin / gist:1285295
Created October 13, 2011 19:43
country stone rails 3.0.10 specs
Hobbes-iMac:countrystone $ rspec spec
No DRb server is running. Running in local process instead ...
cleaning out account types
Seeding account types...
1) SalesOrder instance methods .on_time? should return true if payment_date is neither late nor early
Failure/Error: so.on_time?(Date.today).should == true
expected: true
got: false (using ==)
# ./spec/models/sales_order_spec.rb:505:in `block (3 levels) in <top (required)>'
@bmishkin
bmishkin / gist:1285293
Created October 13, 2011 19:43
countrystone rails 3.0.10 cukes
Hobbes-iMac:countrystone $ cucumber features
Using the default profile...
cleaning out the test database....
Seeding some basic person and roles data....
Seeding account types...
1)
no link with title, id or text 'Show' found (Capybara::ElementNotFound)
./features/step_definitions/web_steps.rb:35:in `block (2 levels) in <top (required)>'
./features/step_definitions/web_steps.rb:14:in `with_scope'
@bmishkin
bmishkin / gist:1285215
Created October 13, 2011 19:15
latest cukes for country stone
Hobbes-iMac:countrystone $ cucumber features
Using the default profile...
cleaning out the test database....
Seeding some basic person and roles data....
Seeding account types...
1)
no link with title, id or text 'Show' found (Capybara::ElementNotFound)
./features/step_definitions/web_steps.rb:35:in `block (2 levels) in <top (required)>'
./features/step_definitions/web_steps.rb:14:in `with_scope'