Skip to content

Instantly share code, notes, and snippets.

# From running `shellcheck --exclude=SC1090,SC1091,SC2034,SC2039,SC2148,SC2153,SC2154 dotnet-core/plan.sh powershell/plan.sh`:
In dotnet-core/plan.sh line 38:
-exec patchelf --interpreter "$(pkg_path_for glibc)/lib/ld-linux-x86-64.so.2" --set-rpath $LD_RUN_PATH {} \;
^-- SC2086: Double quote to prevent globbing and word splitting.
In dotnet-core/plan.sh line 40:
-exec patchelf --set-rpath $LD_RUN_PATH {} \;
^-- SC2086: Double quote to prevent globbing and word splitting.
[106][default:/hab/pkgs/smith/dotnet-core/1.0.0-preview2-003121/20160723182725/shared/Microsoft.NETCore.App/1.0.0:0]# ldd *.so
System.Globalization.Native.so:
linux-vdso.so.1 (0x00007fffe695b000)
libicuuc.so.50 => not found
libicui18n.so.50 => not found
libstdc++.so.6 => not found
libm.so.6 => /hab/pkgs/core/glibc/2.22/20160612063629/lib/libm.so.6 (0x00007fa84cb83000)
libgcc_s.so.1 => not found
libc.so.6 => /hab/pkgs/core/glibc/2.22/20160612063629/lib/libc.so.6 (0x00007fa84c7df000)
/hab/pkgs/core/glibc/2.22/20160612063629/lib64/ld-linux-x86-64.so.2 (0x0000564019dd1000)
require "excon"
require "platform-api"
require "pry"
app = "smith-fronty"
heroku = PlatformAPI.connect_oauth("abcdefg")
`rm -f #{ENV['HOME']}/app.tar.gz && cd #{ENV['HOME']}/Projects/railsconf_fronty && tar cfz #{ENV['HOME']}/app.tar.gz *`
source = heroku.source.create(app)
@smith
smith / iee754
Created April 8, 2016 18:59
ieee 754 lol
nathansmith@opstop ~> pry
[1] pry(main)> 0.1 + 0.2
=> 0.30000000000000004
[2] pry(main)>
nathansmith@opstop ~> python
Python 2.7.4 (default, May 6 2013, 00:06:59)
[GCC 4.2.1 Compatible Apple LLVM 4.2 (clang-425.0.28)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> 0.1 + 0.2
0.30000000000000004
@smith
smith / requests.rb
Created November 5, 2013 02:39
Making an https request in ruby
string_uri = 'https://api.opscode.piab/organizations/test/nodes'
# Using Net::HTTP
require 'net/http'
require 'openssl'
require 'uri'
uri = URI.parse('https://api.opscode.piab/organizations/test/nodes')
http = Net::HTTP.new(uri.host, uri.port)
@smith
smith / nodes.js
Last active December 27, 2015 07:09
An example of using chef-zero for integration testing chef-node
var spawn = require('child_process').spawn,
chef = require('../../chef'),
key = require('fs').readFileSync(__dirname + '/../fixtures/example.pem'),
expect = require('chai').expect;
describe('Nodes', function () {
before(function () {
var chefZero = this.chefZero = spawn('chef-zero', ['--port=8889']);
chefZero.on('exit', function (code, signal) {
if (code !== 0) { throw new Error('Chef Zero exited unexpectedly.'); }
@smith
smith / Notes On Strange Loop 2013.md
Last active December 23, 2015 17:09
Notes On Strange Loop 2013

Notes On Strange Loop 2013

The second Strange Loop I've attended was truly an amazing conference like no other. Last year's was fantastic, but this year was just, well, you really had to be there. Even so, I'll try to give a summary of stuff that happened.

Negatives

To get it out of the way now, these are the things I didn't like:

@smith
smith / requirejs.yml
Last active December 21, 2015 20:09
RequireJS setup of Tabby
shim:
jquery.textarea:
deps: [jquery]
paths:
jquery.textarea: jquery.textarea-0.12 # if you have vendor/assets/javascripts/jquery.textarea-0.12.js
# use with require('jquery.textarea')
@smith
smith / crest.txt
Last active December 16, 2015 08:19
Shryock Family Crest
+-----------+
| |
| ☜(゚ヮ゚☜) |
| |
| ౿(ఠ_ఠఎ) |
| |
| ಠ_ಠ |
x x
xx xxx
xx xx
[2013-03-24T22:00:44-05:00] DEBUG: Saving the current state of node mira.cramerdev.net
[2013-03-24T22:00:44-05:00] DEBUG: Signing the request as mira.cramerdev.net
[2013-03-24T22:00:44-05:00] DEBUG: String to sign: 'Method:PUT
Hashed Path:2mM6K+p/MNcRK9tuoNhmssqn/cU=
X-Ops-Content-Hash:V3QwYvbwyHEKl/7FxVsKyM55ysU=
X-Ops-Timestamp:2013-03-25T03:00:44Z
X-Ops-UserId:mira.cramerdev.net'
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"mira.cramerdev.net", "X-Ops-Timestamp"=>"2013-03-25T03:00:44Z", "X-Ops-Content-Hash"=>"V3QwYvbwyHEKl/7FxVsKyM55ysU=", "X-Ops-Authorization-1"=>"Nz+Gy1JRggw8ixZTWJfpN/drRuvVKqAnLNWX5+AD0vbJh5rOAR6JE7Vo3+95", "X-Ops-Authorization-2"=>"EQ6ToLwYjTn/E6UtMvWDtfmrFFmHlufwTRzg1QjXIOfqdNSNOC1esZaCcRRL", "X-Ops-Authorization-3"=>"xRGeMo7LkzFRtfCxlotG7e78DH9eYNhUZ8PEPF3ZFLDpfJ4qXaMuQBy+qQDM", "X-Ops-Authorization-4"=>"Q2jEL02XrRxwifOQn6o45hJgc0KwS/VbZaHP8bVPzJ96NaIKfpefAMVkw0e4", "X-Ops-Authorization-5"=>"zwDOvtWcujEPGJ++R+iGOrpnpmqh1B4oTrNqzfTuZ1NrV+KgadgJ6mXG/3Li",