Skip to content

Instantly share code, notes, and snippets.

View felixbuenemann's full-sized avatar
💭
I may be slow to respond.

Felix Bünemann felixbuenemann

💭
I may be slow to respond.
View GitHub Profile
@felixbuenemann
felixbuenemann / em-108-arm-kqueue-writer-failed-testcase.rb
Last active August 28, 2015 23:50
Testcase to reproduce kqueue crash with thin on eventmachine 1.0.8
#!/usr/bin/env ruby
begin
require 'bundler/inline'
rescue LoadError => e
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler'
raise e
end
gemfile(true) do
source 'https://rubygems.org'
diff --git a/pom.xml b/pom.xml
index 0ee28a9..320c0c1 100644
--- a/pom.xml
+++ b/pom.xml
@@ -49,9 +49,9 @@
</dependency>
<dependency>
- <groupId>org.jvnet.hudson.plugins</groupId>
+ <groupId>org.jenkins-ci.plugins</groupId>
# encoding: utf-8
# Simple UUID Generator for UUID v0 (zero padded), v1, v2, v3, v4, v5
# Author: Felix Buenemann https://github.com/felixbuenemann/
# License: Public Domain
# Note: v1 code partially based on these ruby uuid implementations:
# https://github.com/assaf/uuid/
# https://github.com/cassandra-rb/simple_uuid
require 'digest/md5'
require 'digest/sha1'
require 'securerandom'
diff --git a/lib/acts_as_tree.rb b/lib/acts_as_tree.rb
index 3279d87..1395481 100644
--- a/lib/acts_as_tree.rb
+++ b/lib/acts_as_tree.rb
@@ -240,7 +240,7 @@ module ActsAsTree
# subchild1.leaf? # => true
# child1.leaf? # => false
def leaf?
- children.empty?
+ children.size == 0
diff -ur activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb
--- activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb 2014-07-11 02:35:32.000000000 +0200
+++ activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb 2014-07-11 01:31:14.000000000 +0200
@@ -8,7 +8,7 @@
# Abstract representation of an index definition on a table. Instances of
# this type are typically created and returned by methods in database
# adapters. e.g. ActiveRecord::ConnectionAdapters::AbstractMysqlAdapter#indexes
- class IndexDefinition < Struct.new(:table, :name, :unique, :columns, :lengths, :orders, :where, :type, :using) #:nodoc:
+ class IndexDefinition < Struct.new(:table, :name, :unique, :columns, :lengths, :orders, :where, :type, :using, :opclass) #:nodoc:
end
unless File.exist?('Gemfile')
File.write('Gemfile', <<-GEMFILE)
source 'https://rubygems.org'
gem 'rails', github: 'rails/rails'
gem 'arel', github: 'rails/arel'
gem 'rack', github: 'rack/rack'
gem 'i18n', github: 'svenfuchs/i18n'
gem 'sqlite3'
GEMFILE
diff --git a/actions.go b/actions.go
index 93cb126..69a4235 100644
--- a/actions.go
+++ b/actions.go
@@ -179,11 +179,18 @@ func sendEmail(e *EmailNotifier, doc bytes.Buffer) error {
} else {
util.Debug("Sending email to %s", e.To)
util.Debug("Sending email:\n%s", string(doc.Bytes()))
- auth := smtp.PlainAuth("", e.Username, e.Password, e.Host)
- err := smtp.SendMail(e.Host+":587", auth, e.From,
# Activate the gem you are reporting the issue against.
gem 'activerecord', '4.1.8'
require 'active_record'
require 'minitest/autorun'
require 'logger'
# Ensure backward compatibility with Minitest 4
Minitest::Test = MiniTest::Unit::TestCase unless defined?(Minitest::Test)
# This connection will do for database-independent bug reports.
" Vim color scheme
"
" Name: railscast.vim
" Maintainer: Josh O'Rourke <joshorourke@me.com>
" License: public domain
"
" A GUI Only port of the RailsCasts TextMate theme [1] to Vim.
" Some parts of this theme were borrowed from the well-documented Lucius theme [2].
" Ported for 256 color console vim by Felix Buenemann <felix.buenemann@gmail.com>
"
--
-- PostgreSQL database dump
--
SET statement_timeout = 0;
SET lock_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SET check_function_bodies = false;
SET client_min_messages = warning;