ruby-processing 2.4.1 → 2.4.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9e35013f3111ccdac477b271d45a0774a6dfd6cb
4
- data.tar.gz: c0ba3dc3c1b5c87ded476f3bb189d363a0d160d4
3
+ metadata.gz: 9941a815cfe461f91e8276a38dc04b779e6a5433
4
+ data.tar.gz: 2f8a60fa95307af91dc82c5e7cc0a87cbf68f7d3
5
5
  SHA512:
6
- metadata.gz: ecdb759d819121d7e12b51e8cf718d5cbc9cb8ce1a5054ca1edee7360b3d798b08d3c6099c61f7a233bdd0e08f9dfffb4e7dd989324f7f4bbb38c06d86decd6d
7
- data.tar.gz: fd8eff69ce65e76ba53c2225468e01f115659541edffa9ce80ed7c423764899fcb308811b7bd345894aac1b30ffdf0588b903fcdc47861aa29839ee543a5a46e
6
+ metadata.gz: cf0f7703d59a95ad938025098a3407b9f5a7b6d2640830e7750c9d3ddd3219912117d33de94c8cf474fd5c2978644307a8bb9370243020592ad13a3f662450b2
7
+ data.tar.gz: c60b0d6ebce9418fe2ced947505fa1f717a1fd44891ccb3a2cbd5f22655e97995e1be7a21fd7b249b7f3f52fda241e8c2a510cd9dd116927056d5e7c7e211582
data/CHANGELOG CHANGED
@@ -1,10 +1,12 @@
1
- v2.4.2 First release to to return to rubygems since processing 1.0.11
1
+ v2.4.2 Update to JRuby-1.7.10
2
+ * Revised suggestions for PROCESSING_ROOT on MacOSX
3
+
4
+ v2.4.1 First release to return to rubygems since processing 1.0.11
2
5
  * Features a post-install download of jruby-complete (version 1.7.9)
3
6
  * Features use of jars from an installed version of vanilla processing,
4
7
  * on linux and windows use version 2.1.0 (later versions may also work).
5
8
  * For Mac, especially if you are using Mac "java" stick with version 2.0.3
6
-
7
- v2.4.1 Update gemspec to match modern expectations
9
+ * Update gemspec to match modern expectations
8
10
 
9
11
  v2.4.0 Returning to rubygems distribution, by not including any jars
10
12
  * Use jars from an installed version of vanilla processing-2.0.3 (or version 2.1.0 linux and windows)
data/LICENSE.md CHANGED
@@ -3,7 +3,7 @@ You can do pretty much whatever you'd like with it.
3
3
 
4
4
  ___
5
5
 
6
- Copyright (c) 2008 omygawshkenas
6
+ Copyright (c) 2008-2014 omygawshkenas
7
7
 
8
8
  Permission is hereby granted, free of charge,
9
9
  to any person obtaining a copy of this software
data/README.md CHANGED
@@ -1,4 +1,5 @@
1
1
  # Ruby-Processing
2
+ [![Gem Version](https://badge.fury.io/rb/ruby-processing.png)](http://badge.fury.io/rb/ruby-processing)
2
3
 
3
4
  Is a ruby wrapper around the [Processing][] code art framework, built using [JRuby][].
4
5
 
@@ -11,17 +12,19 @@ Is a ruby wrapper around the [Processing][] code art framework, built using [JRu
11
12
 
12
13
  ## Installation
13
14
 
14
- Ideally you should install [jruby](http://jruby.org/download), at the very least you will have at least ruby-1.9.3 installed. You should [download][] and install vanilla [processing-2.0.3](https://processing.org/download/) (MacOSX) or [processing-2.1.0](https://processing.org/download/) (Windows, Linux) prior to installing this version of ruby-processing. You must also set the `PROCESSING_ROOT` in the .rp5rc yaml configuration file, the easiest way is by running the [SetProcessingRoot.pde](https://gist.github.com/monkstone/7438749) sketch in the processing ide. The vendored jruby-complete-1.7.9 is added by running `install_jruby_complete` post install (required for application export), see wiki.
15
+ Ideally you should install [jruby](http://jruby.org/download), at the very least you will have at least ruby-1.9.3 installed. You should [download][] and install vanilla [processing-2.0.3](https://processing.org/download/) (MacOSX) or [processing-2.1.0](https://processing.org/download/) (Windows, Linux) prior to installing this version of ruby-processing. You must also set the `PROCESSING_ROOT` in the .rp5rc yaml configuration file, the easiest way is by running the [SetProcessingRoot.pde](https://gist.github.com/monkstone/7438749) sketch in the processing ide.
15
16
 
16
17
  Then install ruby-processing (from rubygems-org) in the usual way
17
18
 
18
- `gem install ruby-processing` some systems eg Ubuntu my require `sudo` access
19
+ `gem install ruby-processing` some systems eg Ubuntu may require `sudo` access
19
20
 
20
- To install jruby-complete use our built in tool (relies on `wget` to download [jruby-complete-1.7.9](http://jruby.org/download))
21
+ To install jruby-complete use our built in tool (relies on `wget` to download [jruby-complete-1.7.10](http://jruby.org/download))
21
22
 
22
23
  `install_jruby_complete`
23
24
 
24
- If you haven't got `wget` just download jruby-complete-1.7.9 to the vendors folder (then run above tool)
25
+ If you haven't got `wget` just download jruby-complete-1.7.10 to the vendors folder (then run above tool)
26
+
27
+ The vendored jruby-complete-1.7.10 is only required for application export, and running certain sketches (eg shader sketches see wiki).
25
28
 
26
29
 
27
30
  ## Documentation
@@ -17,7 +17,7 @@ module Processing
17
17
  def export!(sketch)
18
18
  # Check to make sure that the main file exists
19
19
  @main_file_path, @main_file, @main_folder = *get_main_file(sketch)
20
- usage( @main_file_path && File.exists?(@main_file_path) )
20
+ usage( @main_file_path && File.exist?(@main_file_path) )
21
21
 
22
22
  extract_information
23
23
 
@@ -47,7 +47,7 @@ module Processing
47
47
  @necessary_files += @real_requires
48
48
  NECESSARY_FOLDERS.each do |folder|
49
49
  resource_path = File.join(@main_folder, folder)
50
- @necessary_files << resource_path if File.exists?(resource_path)
50
+ @necessary_files << resource_path if File.exist?(resource_path)
51
51
  end
52
52
  @necessary_files.uniq!
53
53
  cp_r(@necessary_files, File.join(@dest, @prefix))
@@ -115,7 +115,7 @@ module Processing
115
115
  end
116
116
 
117
117
  def wipe_and_recreate_destination
118
- remove_entry_secure @dest if File.exists?(@dest)
118
+ remove_entry_secure @dest if File.exist?(@dest)
119
119
  mkdir_p @dest
120
120
  end
121
121
 
@@ -10,7 +10,7 @@ module Processing
10
10
  usage path
11
11
  main_file = File.basename(path, ".rb")
12
12
  # Check to make sure that the main file exists
13
- already_exists = File.exists?(path) || File.exists?("#{File.dirname(path)}/#{main_file.underscore}.rb")
13
+ already_exists = File.exist?(path) || File.exist?("#{File.dirname(path)}/#{main_file.underscore}.rb")
14
14
  if already_exists
15
15
  puts "That sketch already exists."
16
16
  exit
@@ -113,7 +113,7 @@ module Processing
113
113
  "#{@sketchbook_library_path}/#{library_name}/library",
114
114
  "#{@sketchbook_library_path}/#{library_name}"
115
115
  ].each do |path|
116
- if File.exists?(path) && !Dir.glob(path + "/*.#{ext}").empty?
116
+ if File.exist?(path) && !Dir.glob(path + "/*.#{ext}").empty?
117
117
  return path
118
118
  end
119
119
  end
@@ -161,7 +161,7 @@ module Processing
161
161
  arg_file = "#{File.dirname(sketch)}/data/java_args.txt"
162
162
  args = []
163
163
  args += dock_icon
164
- if File.exists?(arg_file)
164
+ if File.exist?(arg_file)
165
165
  args += File.read(arg_file).split(/\s+/)
166
166
  elsif Processing::CONFIG["java_args"]
167
167
  args += Processing::CONFIG["java_args"].split(/\s+/)
@@ -171,12 +171,12 @@ module Processing
171
171
  end
172
172
 
173
173
  def ensure_exists(sketch)
174
- puts "Couldn't find: #{sketch}" and exit unless File.exists?(sketch)
174
+ puts "Couldn't find: #{sketch}" and exit unless File.exist?(sketch)
175
175
  end
176
176
 
177
177
  def jruby_complete
178
178
  rcomplete = File.join(RP5_ROOT, 'lib/ruby/jruby-complete.jar')
179
- if File.exists?(rcomplete)
179
+ if File.exist?(rcomplete)
180
180
  return rcomplete
181
181
  else
182
182
  warn "#{rcomplete} does not exist\nTry running `install_jruby_complete`"
@@ -2,7 +2,8 @@
2
2
  # This flavor will either load up empty Ruby-Processing,
3
3
  # or will start with your sketch.
4
4
 
5
- require "#{File.dirname(__FILE__)}/base.rb"
5
+ root = File.dirname(__FILE__)
6
+ require "#{root}/base.rb"
6
7
  Processing.load_and_run_sketch
7
8
 
8
9
  ARGV.clear # So that IRB doesn't try to load them as files.
@@ -19,7 +19,7 @@ module Processing
19
19
  def start_watching
20
20
  start_runner
21
21
  loop do
22
- if @files.detect { |file| File.exists?(file) && File.stat(file).mtime > @time }
22
+ if @files.detect { |file| File.exist?(file) && File.stat(file).mtime > @time }
23
23
  puts "reloading sketch..."
24
24
  $app && $app.close
25
25
  @time = Time.now
@@ -1,3 +1,3 @@
1
1
  module RubyProcessing
2
- VERSION="2.4.1"
2
+ VERSION="2.4.2"
3
3
  end
@@ -44,8 +44,8 @@ Gem::Specification.new do |spec|
44
44
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
45
45
 
46
46
  spec.add_development_dependency "bundler", "~> 1.3"
47
- spec.add_development_dependency "rake"
48
- spec.add_development_dependency 'minitest'
47
+ spec.add_development_dependency "rake", "~> 10.0"
48
+ spec.add_development_dependency "minitest", "~> 5.1"
49
49
  spec.requirements << 'A decent graphics card'
50
50
  spec.requirements << 'java runtime >= 1.6+'
51
51
  spec.requirements << 'processing = 2.0.3+'
@@ -17,7 +17,6 @@ attr_accessor :x_wiggle, :y_wiggle, :magnitude, :bluish, :panel, :laf, :hide
17
17
 
18
18
  def setup
19
19
  size 600, 600
20
- @show = false
21
20
  control_panel do |c|
22
21
  c.look_feel "Nimbus"
23
22
  c.slider :bluish, 0.0..1.0, 0.5
@@ -15,7 +15,7 @@ def setup
15
15
  smooth
16
16
  @recording = false
17
17
  directory = "output"
18
- Dir::mkdir(directory) unless File.exists?(directory)
18
+ Dir::mkdir(directory) unless File.exist?(directory)
19
19
  end
20
20
 
21
21
  def draw
@@ -28,7 +28,16 @@ class Rp5Test < Minitest::Test
28
28
  end
29
29
  assert_match %r%ok%, out, "Failed P2D sketch"
30
30
  end
31
-
31
+
32
+ def test_proc_root
33
+ require 'psych'
34
+ path = File.expand_path("~/.rp5rc")
35
+ config = File.exist?(path)? Psych.load_file(path) : {}
36
+ root = config.empty? ? '' : config['PROCESSING_ROOT']
37
+ assert root =~ /processing/, "You need to set your PROCESSING_ROOT in .rp5rc"
38
+ end
39
+
40
+
32
41
  def test_p3d
33
42
  out, err = capture_io do
34
43
  open("|../bin/rp5 run p3d.rb", "r") do |io|
@@ -1,6 +1,6 @@
1
1
  require 'rake/clean'
2
2
 
3
- JRUBY_VERSION = "1.7.9"
3
+ JRUBY_VERSION = "1.7.10"
4
4
 
5
5
  CLOBBER.include("jruby-complete-#{JRUBY_VERSION}.jar")
6
6
 
@@ -12,7 +12,7 @@ task :download => ["jruby-complete-#{JRUBY_VERSION}.jar"]
12
12
 
13
13
  file "jruby-complete-#{JRUBY_VERSION}.jar" do
14
14
  sh "wget http://jruby.org.s3.amazonaws.com/downloads/#{JRUBY_VERSION}/jruby-complete-#{JRUBY_VERSION}.jar"
15
- check_sha1("jruby-complete-#{JRUBY_VERSION}.jar", "93c1906ed4d212ec7fb2fc810da206f1f2a034b4")
15
+ check_sha1("jruby-complete-#{JRUBY_VERSION}.jar", "f74a8b29da11e2ea430a1d1d92b72d424f7ee311")
16
16
  end
17
17
 
18
18
  directory "../lib/ruby"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-processing
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.4.1
4
+ version: 2.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Ashkenas
@@ -18,7 +18,7 @@ authors:
18
18
  autorequire:
19
19
  bindir: bin
20
20
  cert_chain: []
21
- date: 2013-12-22 00:00:00.000000000 Z
21
+ date: 2014-01-10 00:00:00.000000000 Z
22
22
  dependencies:
23
23
  - !ruby/object:Gem::Dependency
24
24
  name: bundler
@@ -38,30 +38,30 @@ dependencies:
38
38
  name: rake
39
39
  requirement: !ruby/object:Gem::Requirement
40
40
  requirements:
41
- - - ">="
41
+ - - "~>"
42
42
  - !ruby/object:Gem::Version
43
- version: '0'
43
+ version: '10.0'
44
44
  type: :development
45
45
  prerelease: false
46
46
  version_requirements: !ruby/object:Gem::Requirement
47
47
  requirements:
48
- - - ">="
48
+ - - "~>"
49
49
  - !ruby/object:Gem::Version
50
- version: '0'
50
+ version: '10.0'
51
51
  - !ruby/object:Gem::Dependency
52
52
  name: minitest
53
53
  requirement: !ruby/object:Gem::Requirement
54
54
  requirements:
55
- - - ">="
55
+ - - "~>"
56
56
  - !ruby/object:Gem::Version
57
- version: '0'
57
+ version: '5.1'
58
58
  type: :development
59
59
  prerelease: false
60
60
  version_requirements: !ruby/object:Gem::Requirement
61
61
  requirements:
62
- - - ">="
62
+ - - "~>"
63
63
  - !ruby/object:Gem::Version
64
- version: '0'
64
+ version: '5.1'
65
65
  description: "\n Ruby-Processing is a Ruby wrapper for the Processing code art framework.
66
66
  It's\n this thin little shim that squeezes between Processing and JRuby, passing\n
67
67
  \ along some neat goodies like:\n\n * Application exporting of your sketches. Hand
@@ -866,3 +866,4 @@ test_files:
866
866
  - test/p3d.rb
867
867
  - test/rp5_test.rb
868
868
  - test/setup_ex.rb
869
+ has_rdoc: