Skip to content

Commit 68856df

Browse files
authored
Merge branch 'master' into stretch
2 parents 76b2525 + ed4ebd7 commit 68856df

13 files changed

Lines changed: 22 additions & 22 deletions

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
v1.1.0 Bring up to date with latest development branch, except still target Stretch and Oracle jdk8, add Gemfile to help version locking.
22

3-
v1.0.0 Earlier code targetting Stretch
3+
v1.0.0 Release for Raspbian Stretch and Oracle java
44

55
v0.9.0 Remove unnecessary MacOS variations, bump examples version
66

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,13 @@ jgem install picrate -v 1.1.0 # NB: important to specify version
1414

1515
Clone this repo:-
1616

17-
Requires maven, openjdk11+ (to build, uses `release` flag), and a jdk8 and jruby to install.
17+
Requires java to build, but uses a maven wrapper so you don't need to install maven. Suggest build/test on regular linux box, but is designed for use on RaspberryPI 3B+. Needs installed jruby to test/run.
1818

1919
```bash
2020
cd PiCrate
2121
rake # assumes an installed version of vanilla processing
2222
jgem install picrate-1.1.0-java.gem
23+
2324
```
2425
To create a template sketch:-
2526
```bash

Rakefile

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ task default: %i[init compile install test gem]
99
# depends on installed processing, with processing on path
1010
desc 'Copy Jars'
1111
task :init do
12+
# for Archlinux etc
13+
# processing_root = File.dirname(`readlink -f $(which processing)`)
14+
# alternative for debian linux etc
1215
processing_root = File.join(HOME_DIR, 'processing-3.5.3')
1316
jar_dir = File.join(processing_root, 'core', 'library')
1417
opengl = Dir.entries(jar_dir).grep(/amd64|armv6hf/).select { |jar| jar =~ /linux/ }
@@ -40,11 +43,11 @@ end
4043

4144
desc 'Test'
4245
task :test do
43-
system 'jruby test/helper_methods_test.rb'
44-
system 'jruby test/respond_to_test.rb' # Skip this test on Travis etc
45-
system 'jruby test/math_tool_test.rb'
46-
system 'jruby test/deglut_spec_test.rb'
47-
system 'jruby test/vecmath_spec_test.rb'
46+
system 'jruby --dev test/helper_methods_test.rb'
47+
system 'jruby --dev test/respond_to_test.rb' # Skip this test on Travis etc
48+
system 'jruby --dev test/math_tool_test.rb'
49+
system 'jruby --dev test/deglut_spec_test.rb'
50+
system 'jruby --dev test/vecmath_spec_test.rb'
4851
end
4952

5053
desc 'clean'

lib/picrate.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# frozen_string_literal: true
2+
23
require 'java'
34
unless defined? PICRATE_ROOT
45
$LOAD_PATH << File.dirname(__dir__)

lib/picrate/runner.rb

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,12 +80,13 @@ def install(library = nil)
8080
library ||= 'new'
8181
choice = library.downcase
8282
case choice
83-
when /samples|sound|video|glvideo/
84-
system "cd #{PICRATE_ROOT}/vendors && rake install_#{choice}"
83+
when /samples|sound|video/
84+
system "cd #{PICRATE_ROOT}/vendors && rake download_and_copy_#{choice}"
8585
when /new/
86+
# install samples and config geany
8687
system "cd #{PICRATE_ROOT}/vendors && rake"
8788
else
88-
warn format('No installer for %s', choice)
89+
warn format('No installer for %s', library)
8990
end
9091
end
9192
end

lib/picrate/version.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# frozen_string_literal: true
2+
23
module PiCrate
34
VERSION = '1.1.0'
45
end

test/color_group_test.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# frozen_string_literal: true
2+
23
require_relative 'test_helper'
3-
require 'java'
4-
require_relative '../lib/picrate'
54
require_relative '../library/color_group/color_group'
65

76
Java::Monkstone::PicrateLibrary.new.load(JRuby.runtime, false)

test/deglut_spec_test.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
require_relative 'test_helper'
2-
require 'java'
3-
require_relative '../lib/picrate'
42

53
Dir.chdir(File.dirname(__FILE__))
64

test/helper_methods_test.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# frozen_string_literal: true
2+
23
require_relative 'test_helper'
3-
require 'java'
4-
require_relative '../lib/picrate'
54

65
Java::Monkstone::PicrateLibrary.new.load(JRuby.runtime, false)
76

test/math_tool_test.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
require_relative 'test_helper'
2-
require 'java'
3-
require_relative '../lib/picrate'
42

53
Java::Monkstone::PicrateLibrary.new.load(JRuby.runtime, false)
64

0 commit comments

Comments
 (0)