Skip to content

Instantly share code, notes, and snippets.

import de.flapdoodle.embed.mongo.Paths;
class CustomPackageResolver extends Paths {
public CustomPackageResolver(Command command) {
super(command);
}
@Override
public String getPath(Distribution distribution) {
String versionStr = getVersionPart(distribution.version());
@robin850
robin850 / gist:5890596
Last active December 19, 2015 03:29
Try not to forget about [ci skip]
# touch .git/hooks/post-commit
# chmod u+x .git/hooks/post-commit
# Enjoy!
#!/usr/bin/env ruby
puts "\033[01;31mDid you use [ci skip]?\033[00;00m"
@robin850
robin850 / gist:5540550
Last active December 17, 2015 03:08
Ruby vs Python (in my opinion)

Ruby Vs Python

Where Python > Ruby

  • Chained comparisons (3 < 5 < 7 => True) ; Exception in Ruby

Where Ruby > Python

  • puts "foo" if condition
  • IdentationError sucks!

Bamboo

Bamboo is a little Ruby script to reorganize Dojo Toolkit assets. It's designed to reorganize correctly assets for a Ruby on Rails structure for the dojo-rails gem since Rails needs to seperate stylesheets, javascripts and images. The script is pretty simple but needs some dependencies. To install them, just run

$ gem install path rubyzip progressbar

Then just clone the gist (the Ruby code) and execute the script. You need to specify an archive or a folder to reorganize :