Moved to https://gist.github.com/dkubb/28403
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gem list '\A(?:(?:d[mo])[_-]|data_?(?:mapper|objects)|extlib)' --no-versions \ | |
| xargs gem uninstall -aIx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.dirname(__FILE__) + '/spec_helper' | |
describe "The library itself" do | |
Spec::Matchers.define :have_no_tab_characters do | |
match do |filename| | |
@failing_lines = [] | |
File.readlines(filename).each_with_index do |line,number| | |
@failing_lines << number + 1 if line =~ /\t/ | |
end | |
@failing_lines.empty? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tail -0f test.log | ruby -ne 'open("|mailx -s Log [email protected]", "w", &:print)' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
git branch -r --merged | \ | |
awk -F/ '!/>|master/&&/origin/{print $2}' | \ | |
xargs git push origin --delete |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Cookbook Name:: jenkins | |
# Recipe:: default | |
# | |
# https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+on+Ubuntu | |
# This is super-simple, compared to the other Chef cookbook I found | |
# for Jenkins (https://github.com/fnichol/chef-jenkins). | |
# | |
# This doesn't include Chef libraries for adding Jenkin's jobs via |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ast = "def foo(a) p a end; foo(1)".to_ast | |
root = Rubinius::AST::Script.new ast | |
root.file = "(heckle)" | |
compiler = Rubinius::Compiler.new :bytecode, :compiled_method | |
compiler.generator.input root | |
cm = compiler.run | |
script = cm.create_script | |
Rubinius.run_script script.compiled_method |
https://github.com/dkubb/veritas
- In Veritas a relation is an Enumerable object that will yield a set of tuples.
- Internally a relation is represented as a tree.
- The leaf nodes are base relations, which are the data sources.
- There are 3 types of inner nodes:
- A node may be a relational algebra operation like join, rename, project or others. When iterated it will evaluate it's children, then perform the operation in-memory and yield each tuple
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git remote update && | |
git remote prune origin && | |
git branch -r --merged origin/master | | |
awk -F"/" '!/(>|master)/ {print $2}' | | |
xargs -rL1 git push origin --delete |
I've done the same process every couple years since 2013 (Mountain Lion, Mavericks, High Sierra, Catalina) and I updated the Gist each time I've done it.
I kinda regret for not using something like Boxen (or anything similar) to automate the process, but TBH I only actually needed to these steps once every couple years...
OlderNewer