Skip to content

Instantly share code, notes, and snippets.

View jscheid's full-sized avatar

Julian Scheid jscheid

View GitHub Profile
irb(main):003:0> RUBY_VERSION
=> "1.9.3"
irb(main):004:0> RUBY_PATCHLEVEL
=> 545
irb(main):005:0> r, w = IO.pipe 'ASCII-8BIT', 'ASCII-8BIT'
=> [#<IO:fd 13>, #<IO:fd 14>]
irb(main):006:0> w.external_encoding
=> #<Encoding:UTF-8>
irb(main):007:0>
diff --git a/roles/debops.rails_deploy/tasks/system.yml b/roles/debops.rails_deploy/tasks/system.yml
index 08959e0..0017e7d 100644
--- a/roles/debops.rails_deploy/tasks/system.yml
+++ b/roles/debops.rails_deploy/tasks/system.yml
@@ -2,12 +2,19 @@
- name: Install app packages
apt: pkg={{ item }} state=latest install_recommends=False
- with_items: rails_deploy_packages
+ with_items: rails_deploy_packages + [ 'git' ]
@jscheid
jscheid / hosts.yml
Created November 29, 2014 13:02
Can't use extra vars in host vars with to_json in 1.8
[dummy]
127.0.0.1 somevar='{{ foo | to_json }}'
bar: 'bar'
foo_json: '{{ foo | to_json }}'

Keybase proof

I hereby claim:

  • I am jscheid on github.
  • I am jscheid (https://keybase.io/jscheid) on keybase.
  • I have a public key whose fingerprint is 7198 317A 9966 BC30 7B89 AFF5 64D5 AD8F 4233 4B48

To claim this, I am signing this object:

@jscheid
jscheid / html-webpack-sri-test.patch
Last active June 11, 2016 00:31
html-webpack-plugin/webpack-subresource-integrity test case example
diff --git a/package.json b/package.json
index 7fba20f..0ba9d1e 100644
--- a/package.json
+++ b/package.json
@@ -4,7 +4,7 @@
"description": "Webpack plugin for ensuring subresource integrity",
"main": "index",
"scripts": {
- "test": "karma start --single-run",
+ "test": "karma start --single-run && mocha test/test-webpack.js",
;;; node-local-flycheck -- Try to use linters from node_modules, and node from nvm -*- lexical-binding: t -*-
;; (C) 2016 Julian Scheid
;; Author: Julian Scheid <julians37@gmail.com>
;; Version: 0.1.0
;; Keywords: convenience flycheck javascript
;; This file is not part of GNU Emacs.
const moment = require('moment');
const CountryLanguage = require('country-language');
const glob = require('glob-promise');
const path = require('path');
const Promise = require('bluebird');
console.log('resolved=', require.resolve('moment'));
const data = {};
@jscheid
jscheid / gist:29dee9816e89a27c71b54fd40719a70f
Last active February 23, 2019 23:30
Upgrade webpack-subresource-integrity with angular-cli
$ yarn --version
1.13.0
$ ng --version
_ _ ____ _ ___
/ \ _ __ __ _ _ _| | __ _ _ __ / ___| | |_ _|
/ △ \ | '_ \ / _` | | | | |/ _` | '__| | | | | | |
/ ___ \| | | | (_| | |_| | | (_| | | | |___| |___ | |
/_/ \_\_| |_|\__, |\__,_|_|\__,_|_| \____|_____|___|
|___/
+ gem install racc
Building native extensions. This could take a while...
Successfully installed racc-1.5.0
Parsing documentation for racc-1.5.0
Done installing documentation for racc after 0 seconds
1 gem installed
+ bundle --gemfile=Gemfile.without-patch --path=without-patch
Using concurrent-ruby 1.1.6
Using i18n 1.8.2
Using minitest 5.14.0