Created
September 14, 2009 02:52
-
-
Save matschaffer/186465 to your computer and use it in GitHub Desktop.
This file contains 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 'pathname' | |
class Buildr::Eclipse::ClasspathEntryWriter | |
alias :_src :src | |
def src arg | |
if arg.respond_to?(:partition) | |
files, sources = arg.partition { |dep| dep.is_a?(String) && Pathname.new(dep).file? } | |
lib files | |
_src sources | |
else | |
_src arg | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment