Skip to content

Instantly share code, notes, and snippets.

View terceiro's full-sized avatar

Antonio Terceiro terceiro

View GitHub Profile
@terceiro
terceiro / 0011-Support-system-installed-plugins.patch
Created May 27, 2015 17:27
support for distro-provided plugins
From: Antonio Terceiro <terceiro@debian.org>
Date: Wed, 27 May 2015 09:36:17 -0300
Subject: Support system-installed plugins
Plugins must be installed as regular Ruby libraries, and they must
contain /usr/share/vagrant-plugins/plugins.d/$PLUGINNAME.json with the
following content:
{
"${PLUGINNAME}": {
@terceiro
terceiro / port-to-ruby2.1.diff
Created April 17, 2014 13:50
port ruby-gsl to Ruby 2.1
--- a/ext/linalg.c
+++ b/ext/linalg.c
@@ -14,6 +14,7 @@
#include "rb_gsl_array.h"
#include "rb_gsl_common.h"
#include "rb_gsl_linalg.h"
+#include "porting.h"
static VALUE cgsl_matrix_LU;
static VALUE cgsl_matrix_QR;
@terceiro
terceiro / code.sh
Created February 6, 2012 18:01
Gems with duplicate names in different case (e.g. MyGem vs mygem)
zcat specs.4.8.gz | ruby -e 'puts Marshal.load(STDIN).map(&:first).uniq' | uniq -ic | awk '{ if ($1 > 1) { print $0 } }'
@terceiro
terceiro / log
Created May 11, 2011 15:28
shoulda-context automated tests broken on ruby 1.9
$ rake1.9.1
(in /home/terceiro/src/debian/pkg-ruby-extras/ruby-shoulda-context)
* DEFERRED: Context should be able to setup a should eventually in a class method.
* DEFERRED: Should should pass, since it's a should_eventually.
* DEFERRED: Context should pass, since it's unimplemented.
* DEFERRED: Context should not require a block when using should_eventually.
* DEFERRED: Context should pass without a block, as that causes it to piggyback to should_eventually.
* DEFERRED: context for testing should piggybacking should call should_eventually as we are not passing a block.
* DEFERRED: context with nested subcontexts should only print this statement once for a should_eventually.
Loaded suite /usr/lib/ruby/1.9.1/rake/rake_test_loader
@terceiro
terceiro / git error when pulling via HTTP
Created February 8, 2010 20:51
SOLVED: git error when pulling via HTTP
error: unknown object type 5 at offset 4464021 in .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: failed to read delta base object 28fa12d1a854b14fbf37999f05964b00471281d7 at offset 4464021 from .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: unknown object type 5 at offset 4458084 in .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: failed to read delta base object bbe0a7e02f0b26c918b7d9e2b2a245b0376ec6b6 at offset 4458084 from .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: inflate: data stream error (incorrect header check)
error: failed to read delta base object 961cbddd398ff0ec229ffa50124bac40b80c39f0 at offset 4464884 from .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: unknown object type 5 at offset 4457057 in .git/objects/pack/pack-206ed5349a0687c7baebeaf9d20f1d4eeb123174.pack
error: failed to read object 53b1c0003620c4f0cb004785240f2b0ce70bb068 at offset 4457057 f