Skip to content

Instantly share code, notes, and snippets.

@marchelbling
marchelbling / gist:c8ef8a2dadbacf3587b292ad9dc1c408
Created January 23, 2018 11:08 — forked from lxneng/gist:741932
install PostgreSQL 9 in Mac OSX via Homebrew
install PostgreSQL 9 in Mac OSX via Homebrew
Mac OS X Snow Leopard
System Version: Mac OS X 10.6.5
Kernel Version: Darwin 10.5.0
Install notes for PostgreSQL 9.0.1 install using Homebrew:
sh-3.2# brew install postgresql
@marchelbling
marchelbling / XPS-15 9560 Getting Nvidia To Work on KDE Neon
Last active June 6, 2017 05:12 — forked from whizzzkid/XPS-15 9560 Getting Nvidia To Work on KDE Neon
Making Nvidia Drivers + CUDA 8 + Bumblebee work together on XPS 15 Early 2017 9560 kabylake.
1. disable secure boot
2. clean install windows (see https://www.reddit.com/r/Dell/comments/5qe3oh/how_to_fresh_install_on_xps_15_9560/)
2.1 in case usb does not show on boot: http://www.dell.com/support/article/us/en/19/SLN297060/xps-13-9343--how-to-install-ubuntu-developer-edition-1404-on-a-dell-pc-configured-for-the-unified-extensible-firmware-interface--uefi--bios?lang=EN
# Update kernel (is this mandatory?)
( mkdir /tmp/kernel-4.10.6
cd /tmp/kernel-4.10.6
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.10.6/linux-headers-4.10.6-041006_4.10.6-041006.201703260832_all.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.10.6/linux-headers-4.10.6-041006-generic_4.10.6-041006.201703260832_amd64.deb
wget http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.10.6/linux-image-4.10.6-041006-generic_4.10.6-041006.201703260832_amd64.deb
@marchelbling
marchelbling / panda.rb
Last active August 29, 2015 14:10 — forked from bsag/panda.rb
#!/usr/bin/env ruby
require 'rubygems'
require 'commander/import'
program :version, '0.1'
program :description, 'Converts markdown documents into a variety of default formats using Pandoc'
CMD = "pandoc"
BIB = "$HOME/Dropbox/Documents/bibtex/all-refs.bib"
@marchelbling
marchelbling / spec1.rb
Created October 4, 2012 19:58 — forked from cheeyeo/spec1.rb
Example on how to mock out an API call using RSpec and EM:Http
before :each do
@url = 'http://sns.us-east-1.amazonaws.com:80/?Action=ListTopics&Signature=ItTAjeexIPC43pHMZLCL7utnpK8j8AbTUZ3KGUSMzNc%3D&AWSAccessKeyId=123456&Timestamp=123&SignatureVersion=2&SignatureMethod=HmacSHA256'
EventMachine::MockHttpRequest.reset_registry!
EventMachine::MockHttpRequest.reset_counts!
EventMachine::MockHttpRequest.pass_through_requests = false #set to false to not hit the actual API endpoint
end
it 'should be able to access the API endpoint' do