Open amiracam opened 7 years ago
Not sure what you want to achieve? Do you actually want to build a JRUby-based jar or do you want to run a Ruby script where the passed parameters are from a specfic configuration of dependencies?
the latter, but I do count on prepareJrubyJar to run which is why I have a dependsOn to it, I basically have hacked a tenable integration with Intellij IDEA, which for now relies on the prepareJrubyJar task running after which I currently scan the build directories for the jars and gems and based on that I generate a .idea/libraries/
To clarify, the steps are for "setupIDEA"
currently counting on the IDEA .iml file having a specific entry i.e. have not gotten yet around to modifying said IDEA config
So I was hoping to grab the gem names / versions and the Jar specifications from Gradle and pass these to the ruby script instead of what I do right now which is to scan over directories and based on the naming of folders and files retrieve the desired information.
What I have works but I would like to understand Gradle a bit better and obviously passing into the ruby scripts the dependency specs is much cleaner.
This morning I figured I could do as follows:
task testScan(type: JRubyExec){ script 'scripts/retrieveSpecs.rb' scriptArgs configurations.jrubyJar.dependencies.collect {"{\"name\":\"${it.name}\" , \"group\": \"${it.group}\", \"version\": \"${it.version}\"}"} }
I then can collect my rubygems group and generate the Gemfile from that and generate the IDEA Jar library configuration from the rest.
Please do suggest what could make this cleaner, thanks
You are on the right track now. I was going to suggest to you to learn about configurations, but I see you have discovered enough to get you going.
yes, I probably should spend more time learning Gradle :) just swamped with building product
hi, its been a while, I had to drop my efforts back then and concentrate on Groovy, is the Jruby Gradle plugin now more tightly integrated with IDEA ? thanks
Not so sure how integrated it is, but it is swiflty evolving into much better functionality.
Ok, I’ll check it out again
Charles A. Monteiro Chief Technology Officer Web: www.tradeblazer.com
On Jun 11, 2019, 5:55 PM -0400, Schalk W. Cronjé notifications@github.com, wrote:
Not so sure how integrated it is, but it is swiflty evolving into much better functionality. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.
forgive my gradle newbieness, been walking thru the code but just could not figure out how to do the following
given:
jrubyJar "rubygems:colorize:0.7.7+" jrubyJar "rubygems:sequel:5.0.0" jrubyJar "rubygems:redis:4.0.0" jrubyJar 'org.slf4j:slf4j-simple:1.7.25' jrubyJar 'io.ratpack:ratpack-base:1.5.0' jrubyJar 'io.ratpack:ratpack-core:1.5.0' jrubyJar 'io.ratpack:ratpack-exec:1.5.0' jrubyJar 'org.slf4j:slf4j-simple:1.7.25'
I want to create a task where I can retrieve the passed in strings to "jrubyJar" , ideally those prefixed by "rubygems:" and subsequently pass those to a ruby script
thanks