Skip to content

Commit

Permalink
Showing 4 changed files with 45 additions and 7 deletions.
5 changes: 4 additions & 1 deletion core/src/main/java/org/jruby/RubyGlobal.java
Original file line number Diff line number Diff line change
@@ -279,7 +279,10 @@ public static void initSTDIO(Ruby runtime, GlobalVariables globals) {
RubyIO stdin, stdout, stderr;

// If we're the main for the process and native stdio is enabled, use default descriptors
if (runtime.getPosix().isNative() && runtime.getInstanceConfig().isHardExit() && Options.NATIVE_STDIO.load()) {
if (!Platform.IS_WINDOWS && // Windows does not do native IO yet
runtime.getPosix().isNative() &&
runtime.getInstanceConfig().isHardExit() && // main JRuby only
Options.NATIVE_STDIO.load()) {
stdin = RubyIO.prepStdio(
runtime, runtime.getIn(), new NativeDeviceChannel(0), OpenFile.READABLE, runtime.getIO(), "<STDIN>");
stdout = RubyIO.prepStdio(
10 changes: 9 additions & 1 deletion maven/jruby-complete/pom.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require 'fileutils'

project 'JRuby Complete' do

version = ENV['JRUBY_VERSION'] ||
File.read( File.join( basedir, '..', '..', 'VERSION' ) ).strip

@@ -111,6 +111,14 @@
execute_goals( 'attach-artifact',
:id => 'attach-artifacts',
'artifacts' => artifacts )

execute_goals( 'attach-artifact',
:id => 'attach-checksums',
'artifacts' => [ { file: '${project.build.directory}/jruby-complete-${project.version}.jar.sha256',
type: 'jar.sha256'},
{ file: '${project.build.directory}/jruby-complete-${project.version}.jar.sha512',
type: 'jar.sha512'} ] )

end
end
end
33 changes: 30 additions & 3 deletions maven/jruby-dist/pom.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
require 'rubygems/package'
require 'fileutils'
project 'JRuby Dist' do

version = ENV['JRUBY_VERSION'] ||
File.read( File.join( basedir, '..', '..', 'VERSION' ) ).strip

@@ -64,9 +64,36 @@
end
end

plugin( :invoker )

plugin( 'net.ju-n.maven.plugins:checksum-maven-plugin' )

plugin( :invoker )
profile 'sonatype-oss-release' do

plugin 'org.codehaus.mojo:build-helper-maven-plugin' do
execute_goals( 'attach-artifact',
id: 'attach-checksums',
phase: :package,
artifacts: [ { file: '${project.build.directory}/jruby-dist-${project.version}-bin.tar.gz.sha256',
classifier: :bin,
type: 'tar.gz.sha256'},
{ file: '${project.build.directory}/jruby-dist-${project.version}-bin.tar.gz.sha512',
classifier: :bin,
type: 'tar.gz.sha512'},
{ file: '${project.build.directory}/jruby-dist-${project.version}-bin.zip.sha256',
classifier: :bin,
type: 'zip.sha256'},
{ file: '${project.build.directory}/jruby-dist-${project.version}-bin.zip.sha512',
classifier: :bin,
type: 'zip.sha512'},
{ file: '${project.build.directory}/jruby-dist-${project.version}-src.zip.sha256',
classifier: :src,
type: 'zip.sha256'},
{ file: '${project.build.directory}/jruby-dist-${project.version}-src.zip.sha512',
classifier: :src,
type: 'zip.sha512'} ] )
end
end

# since the source packages are done from the git repository we need
# to be inside a git controlled directory. for example the source packages
@@ -79,7 +106,7 @@
file( :exists => '../../.git' )
end

phase 'package' do
phase 'prepare-package' do
execute :pack_sources do |ctx|
require 'fileutils'

4 changes: 2 additions & 2 deletions maven/pom.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
project 'JRuby Artifacts' do

version = ENV['JRUBY_VERSION'] ||
File.read( File.join( basedir, '..', 'VERSION' ) ).strip

@@ -28,7 +28,7 @@
execute_goals(
:artifacts,
phase: :package,
algorithms: ['MD5', 'SHA-1', 'SHA-256', 'SHA-512' ] )
algorithms: ['SHA-256', 'SHA-512' ] )
end
end

0 comments on commit 7bf45b0

Please sign in to comment.