This repository has been archived by the owner. It is now read-only.

RubyScriptRunner independent observers' callbacks call #191

Merged
merged 3 commits into from Apr 30, 2016

Conversation

2 participants
@rssdev10
Contributor

rssdev10 commented Mar 25, 2016

Checked for Ruby scripts from IDE only!

Running from external script is impossible now:

./start_test.sh observer_test.rb 

observer_test.rb
[info] runcmd: lsb_release -i -r -s 
NameError: missing class or uppercase package name (`org.sikuli.script.App'), caused by (NameError) cannot link Java class org.sikuli.script.App, probable missing dependency: org/apache/commons/exec/ExecuteStreamHandler
  get_proxy_or_package_under_package at org/jruby/javasupport/JavaUtilities.java:54
                      method_missing at file:/home/rss/.rvm/rubies/jruby-1.7.19/lib/jruby.jar!/jruby/java/java_package_module_template.rb:14
                             Sikulix at /home/rss/.rvm/gems/jruby-1.7.19/gems/sikulix-1.1.0.3/lib/sikulix/sikulix.rb:37
                              (root) at /home/rss/.rvm/gems/jruby-1.7.19/gems/sikulix-1.1.0.3/lib/sikulix/sikulix.rb:7
                             require at org/jruby/RubyKernel.java:1071
                              (root) at /home/rss/.rvm/rubies/jruby-1.7.19/lib/ruby/shared/rubygems/core_ext/kernel_require.rb:1
                             require at /home/rss/.rvm/rubies/jruby-1.7.19/lib/ruby/shared/rubygems/core_ext/kernel_require.rb:54
                             require at org/jruby/RubyKernel.java:1071
                              (root) at /home/rss/.rvm/gems/jruby-1.7.19/gems/sikulix-1.1.0.3/lib/sikulix.rb:4
                              (root) at observer_test.rb:3

Moreover as sikulixapi is without native libs now then an additional jar usage is required. And start_test.sh looks now:

#!/usr/bin/sh

SIKULIXAPI_JAR='sikulixapi-1.1.1.jar'
SIKULIXLIBS_JAR='sikulixlibslux-1.1.1.jar'

export SIKULIXAPI_JAR
export SIKULIXLIBS_JAR

echo $1
ruby $1

observer_test.rb

require 'java'
require ENV['SIKULIXLIBS_JAR']

require 'sikulix'

include Sikulix


onAppear("1392466160677.png") { |e| popup(e.inspect, 'test1') }

@RaiMan RaiMan merged commit 988be4b into RaiMan:master Apr 30, 2016

@RaiMan

This comment has been minimized.

Show comment
Hide comment
@RaiMan

RaiMan Apr 30, 2016

Owner

thanks.
highly appreciated.

Owner

RaiMan commented Apr 30, 2016

thanks.
highly appreciated.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.