Comments (14)
To be able to try out the concept today, one can bastardise JRubyExec
task rubyCompile( type : JRubyExec) {
jrubyArgs '-S', 'jrubyc', '-t', "${buildDir}/classes"
script 'one.rb'
scriptArgs 'two.rb','three.rb'
}
We can look at creating a plugin to do this which allows for creating additional tasks to mirror some of the other compile
tasks i.e. rubyCompile
and rubyTestCompile
, which can live in sourceSets
such as src/main/ruby
and src/test/ruby
. Once we do this we are no longer in the realm of trying to build with rake
and package, but rather treat ruby
as a first class citizen in gradle
, like groovy
, scala
and clojure
.
from jruby-gradle-plugin.
👍
from jruby-gradle-plugin.
Should we revisit this once JRuby 9.0.0.0 is out?
from jruby-gradle-plugin.
I think this still makes sense to provide, but I would no longer go the route I suggested before.
I think a CompileRuby
type task which relies on sourceSets
makes a lot of sense for solving this problem. It's not something I think should go strictly into a task
from jruby-gradle-plugin.
from jruby-gradle-plugin.
+1
from jruby-gradle-plugin.
@mojavelinux or @mcandre would this feature request still be interesting to either of you? I'm cleaning up the backlog, and I personally don't have a requirement for this any longer.
from jruby-gradle-plugin.
To be honest, I don't remember what the use case was. So I don't have an immediate need for it.
from jruby-gradle-plugin.
Just made a gist for an example in Gitter which kind of does this: https://gist.github.com/rtyler/7635e9c110548882504729ff7445ed0b
from jruby-gradle-plugin.
I think this might be straightforward enough to support. I'm going to bring it in to 2.0 like the over-optimistic sucker I am.
from jruby-gradle-plugin.
I think this a great idea, but let's not rush an implementation. We can do a much better job than the quick gist you did.
from jruby-gradle-plugin.
@ysb33r Since you've certainly got an idea in mind for how this should be implemented, would you like to take it on?
If not, perhaps writing up a specification or something like that would help me understand what a good job might look like here to you
from jruby-gradle-plugin.
This will have to be a joint effort as I'll need to understand more about how the ruby compilation is used in practice.
from jruby-gradle-plugin.
The two places I believe ahead-of-time compilation are used/useful for are:
- Speeding things up at runtime, i.e. avoiding that step at runtime.
- Blending Java and Ruby code together in a primarily Java project.
Neither of these are pressing requirements for me personally, but I understand why some people might find them useful 😸
from jruby-gradle-plugin.
Related Issues (20)
- Cannot cast object extension jruby HOT 2
- any version for java 8? HOT 4
- Gradle 7.1 deprecation warnings
- Custom gem repository not working with jruby-gradle-plugin 2.0.1 (plain command line gem does work with the same custom repo in .gemrc) HOT 5
- Requesting non-alpha 2.1.0 release HOT 7
- JRubyPrepare projectOperations missing input or output annotation HOT 1
- JRubyPrepare task fails on Windows Github Actions
- Gradle 7 deprecation warnings HOT 1
- Cannot install Nokogiri 1.14.0 HOT 1
- Test multiple gradle versions using https://github.com/gradle/gradle-build-action
- Remove traces of bintray publishing
- Move packages to dedicated "jruby-gradle" account in plugins.gradle.org HOT 1
- Java 8 support
- Publishing GitHub Pages
- `JRubyExec` doesn't stop on debugger
- 'jruby-gradle-core-plugin` Second Level Dependency Moved/Removed From Maven Central and Gradle Plugin Portal HOT 3
- example run-simple-ruby-script gradlew run error
- `setMain` in `JRubyExec` is removed in Gradle 8 and hence the plugin doesn't work
- `Cannot fingerprint input property 'gemConfiguration'`
- Gradle 8 compatibility?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jruby-gradle-plugin.