posxml_parser 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ba5d049f0a401ca8e784785cc7beb2c1e8adf575
4
+ data.tar.gz: 334892c6d51afa3b7411006154f4603c2dd47f68
5
+ SHA512:
6
+ metadata.gz: 29064193bf24ddf8a0475c95819e3426bdc66f66c450f05d92c783706115d8c638a44bd397c38a5a27df434ac263f48b9c0082a24651670774bc1c877d92d481
7
+ data.tar.gz: 4a1d8cfa6fe369a0c2f8c035d8ed999b09bab84654a1c52e8f54b775d56af71071165e93f0d4dd53a7fe21fb886a0726b1ad2afc0e06a1940859099d00e5d010
@@ -0,0 +1,22 @@
1
+ *.swp
2
+ *.swo
3
+ *.gem
4
+ *.rbc
5
+ *.wsxml
6
+ .bundle
7
+ .config
8
+ .yardoc
9
+ Gemfile.lock
10
+ InstalledFiles
11
+ _yardoc
12
+ coverage
13
+ doc/
14
+ lib/bundler/man
15
+ pkg
16
+ rdoc
17
+ spec/reports
18
+ test/tmp
19
+ test/version_tmp
20
+ tmp/*
21
+ tmp
22
+ out/
data/Gemfile ADDED
@@ -0,0 +1,5 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gem 'da_funk', '~>0.5', :git => 'https://github.com/cloudwalkio/da_funk.git'
4
+
5
+ gemspec
@@ -0,0 +1,70 @@
1
+ # PosxmlParser
2
+
3
+ Funky Library responsible to parse and execute posxml applications.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ gem 'posxml_parser'
10
+
11
+ And then execute:
12
+
13
+ $ bundle install
14
+
15
+ ## MRuby dependencies
16
+
17
+ mruby-mtest (https://github.com/iij/mruby-mtest)
18
+ mruby-io (https://github.com/iij/mruby-io)
19
+ mruby-socket (https://github.com/iij/mruby-socket)
20
+ mruby-pack (https://github.com/iij/mruby-pack)
21
+ mruby-require (https://github.com/iij/mruby-require)
22
+
23
+ ## Usage
24
+
25
+ ### Defauly interpreter
26
+
27
+ PosxmlInterpreter.new.start
28
+
29
+ ### Custom interpreter
30
+
31
+ Configure, customize and run
32
+
33
+ class MyClass
34
+ include PosxmlParser # Include PosxmlParser in your custom class
35
+
36
+ def start
37
+ posxml_configure("/sdcard", "main.posxml") # define working directory and main file
38
+ posxml_loop # start loop execution
39
+ end
40
+
41
+ util_exit do
42
+ # Custom behaviour
43
+ end
44
+
45
+ interface_display(column, line, text) do
46
+ # Custom behaviour
47
+ end
48
+ end
49
+
50
+ MyClass.new.start
51
+
52
+ More details in [posxml_interpreter](lib/posxml_interpreter.rb).
53
+
54
+ ## Tests
55
+
56
+
57
+ $ rake test:unit # execute unit tests
58
+
59
+ $ rake test:integration # execute integration tests
60
+
61
+ $ rake test # execute all tests
62
+
63
+
64
+ ## Contributing
65
+
66
+ 1. Fork it
67
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
68
+ 3. Commit your changes (`git commit -am 'Added some feature'`)
69
+ 4. Push to the branch (`git push origin my-new-feature`)
70
+ 5. Create new Pull Request
@@ -0,0 +1,5 @@
1
+ # Posxml Parser
2
+
3
+ ### 0.6.0 - 2016-01-07 - First stable release.
4
+
5
+ - Support to parse and execute posxml instrucions.
@@ -0,0 +1,43 @@
1
+ #!/usr/bin/env rake
2
+
3
+ require 'rake'
4
+ require 'fileutils'
5
+ require 'bundler/setup'
6
+
7
+ Bundler.require(:default)
8
+ files = [
9
+ "lib/posxml_parser/posxml_error.rb",
10
+ "lib/posxml_parser/bytecode.rb",
11
+ "lib/posxml_parser/class_methods.rb",
12
+ "lib/posxml_parser/instructions.rb",
13
+ "lib/posxml_parser/posxml_emv.rb",
14
+ "lib/posxml_parser/variable.rb",
15
+ "lib/posxml_parser/version.rb",
16
+ "lib/posxml_parser/posxml_setting.rb",
17
+ "lib/posxml_parser.rb",
18
+ "lib/posxml_interpreter.rb"
19
+ ]
20
+
21
+ DaFunk::RakeTask.new do |t|
22
+ t.libs = FileList[files]
23
+ t.debug = false
24
+ FileUtils.rm_rf("./test/tmp")
25
+ FileUtils.cp_r("./test/fixtures", "./test/tmp")
26
+ end
27
+
28
+ desc "Generate posxml_parser gem to upload to RubyGems.org. "
29
+ task :gem do
30
+ puts "Be careful this action will delete and checkout lib/posxml_parser.rb"
31
+ input = ""
32
+ while (input != "y" && input != "n") do
33
+ puts "Are you sure? (Y/N)"
34
+ input = STDIN.gets.to_s.chomp.downcase
35
+ end
36
+
37
+ if input == "y"
38
+ sh "rake"
39
+ sh "rm -f lib/posxml_parser.rb"
40
+ sh "gem build posxml_parser.gemspec"
41
+ sh "git checkout -- lib/posxml_parser.rb"
42
+ end
43
+ end
@@ -0,0 +1,5 @@
1
+
2
+ module PosxmlParser
3
+ VERSION = "0.6.0"
4
+ end
5
+
@@ -0,0 +1,24 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'posxml_parser/version.rb'
5
+
6
+ Gem::Specification.new do |gem|
7
+ gem.name = "posxml_parser"
8
+ gem.version = PosxmlParser::VERSION
9
+ gem.authors = ["CloudWalk Team"]
10
+ gem.email = ["thiago@cloudwalk.io"]
11
+ gem.description = "Funky Library responsible to parse and execute posxml applications."
12
+ gem.summary = "Parse and execute posxml applications."
13
+ gem.homepage = "http://cloudwalk.io"
14
+ gem.license = ""
15
+
16
+ gem.files = %w(.gitignore Gemfile Gemfile.lock README.md RELEASE_NOTES.md Rakefile posxml_parser.gemspec lib/posxml_parser/version.rb out/posxml_parser/main.mrb)
17
+ gem.executables = []
18
+ gem.test_files = gem.files.grep(%r{^(test)/})
19
+ gem.require_paths = ["lib"]
20
+
21
+ gem.add_development_dependency "bundler", "~> 1.7"
22
+ gem.add_development_dependency "rake", "~> 10.0"
23
+ end
24
+
metadata ADDED
@@ -0,0 +1,82 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: posxml_parser
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.6.0
5
+ platform: ruby
6
+ authors:
7
+ - CloudWalk Team
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2016-01-07 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ~>
18
+ - !ruby/object:Gem::Version
19
+ version: '1.7'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.7'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ~>
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ~>
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ description: Funky Library responsible to parse and execute posxml applications.
42
+ email:
43
+ - thiago@cloudwalk.io
44
+ executables: []
45
+ extensions: []
46
+ extra_rdoc_files: []
47
+ files:
48
+ - .gitignore
49
+ - Gemfile
50
+ - Gemfile.lock
51
+ - README.md
52
+ - RELEASE_NOTES.md
53
+ - Rakefile
54
+ - lib/posxml_parser/version.rb
55
+ - out/posxml_parser/main.mrb
56
+ - posxml_parser.gemspec
57
+ homepage: http://cloudwalk.io
58
+ licenses:
59
+ - ''
60
+ metadata: {}
61
+ post_install_message:
62
+ rdoc_options: []
63
+ require_paths:
64
+ - lib
65
+ required_ruby_version: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - '>='
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ required_rubygems_version: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - '>='
73
+ - !ruby/object:Gem::Version
74
+ version: '0'
75
+ requirements: []
76
+ rubyforge_project:
77
+ rubygems_version: 2.2.2
78
+ signing_key:
79
+ specification_version: 4
80
+ summary: Parse and execute posxml applications.
81
+ test_files: []
82
+ has_rdoc: