opal 1.0.4 → 1.0.5
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.
- checksums.yaml +4 -4
- data/.github/workflows/build.yml +15 -7
- data/CHANGELOG.md +12 -1
- data/UNRELEASED.md +0 -2
- data/lib/opal/cli.rb +4 -1
- data/lib/opal/cli_options.rb +10 -3
- data/lib/opal/version.rb +1 -1
- data/opal/corelib/constants.rb +2 -2
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3aa0e89c4ec45d23afb8a14072ab0ef24b7d9e8ef2e0771600dd6e06910f9392
|
4
|
+
data.tar.gz: 7f93b034d7ea2c325ae75f0c2fb8d69168ddae340f25a0422b606df4b1e626e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9a52c4d4d98020e2e970b299c57b27a8860bc6093a916960fde9399c7fc0f61d58b572159a35859c1337d69e4754b08b0f1561ce76332ed9dd9170186e447ed2
|
7
|
+
data.tar.gz: c0902f840424bc3567a813077034eb3c5d174ba5411f3096dcd7bda877066793bfd598e9ddc35b93d1acdb9ff602216e96a337cea9ac06153e7a418c8904ab9f
|
data/.github/workflows/build.yml
CHANGED
@@ -17,8 +17,16 @@ jobs:
|
|
17
17
|
fail-fast: false
|
18
18
|
matrix:
|
19
19
|
combo:
|
20
|
+
- name: mspec-nodejs
|
21
|
+
ruby: 2.7
|
22
|
+
command: bin/rake mspec_nodejs
|
23
|
+
- name: mspec-chrome
|
24
|
+
ruby: 2.7
|
25
|
+
command: bin/rake mspec_chrome
|
26
|
+
- name: minitest
|
27
|
+
ruby: 2.7
|
28
|
+
command: bin/rake minitest
|
20
29
|
- name: current-ruby
|
21
|
-
command: bin/rake
|
22
30
|
ruby: 2.7
|
23
31
|
- name: previous-ruby
|
24
32
|
ruby: 2.6
|
@@ -49,29 +57,29 @@ jobs:
|
|
49
57
|
# NOTE: Bundler 2.2.0 fails to install libv8
|
50
58
|
# https://github.com/rubyjs/libv8/issues/310
|
51
59
|
bundler: "2.1.4"
|
52
|
-
bundler-cache:
|
60
|
+
bundler-cache: false
|
53
61
|
- run: ruby bin/git-submodule-fast-install
|
54
62
|
- run: bundle lock
|
55
63
|
- uses: actions/cache@v2
|
56
64
|
with:
|
57
|
-
path: vendor/bundle
|
65
|
+
path: ./vendor/bundle
|
58
66
|
key: ${{ runner.os }}-${{ matrix.combo.ruby }}-gems-${{ github.ref }}-${{ hashFiles('**/Gemfile.lock') }}
|
59
67
|
restore-keys: |
|
60
68
|
${{ runner.os }}-${{ matrix.combo.ruby }}-gems-${{ github.ref }}
|
61
|
-
${{ runner.os }}-${{ matrix.combo.ruby }}-gems-
|
69
|
+
${{ runner.os }}-${{ matrix.combo.ruby }}-gems-1-0-stable
|
62
70
|
${{ runner.os }}-${{ matrix.combo.ruby }}-gems-
|
63
71
|
- uses: actions/cache@v2
|
64
72
|
with:
|
65
|
-
path: node_modules
|
73
|
+
path: ./node_modules
|
66
74
|
key: ${{ runner.os }}-npm-${{ github.ref }}-${{ hashFiles('**/yarn.lock') }}
|
67
75
|
restore-keys: |
|
68
76
|
${{ runner.os }}-npm-${{ github.ref }}
|
69
|
-
${{ runner.os }}-npm-
|
77
|
+
${{ runner.os }}-npm-1-0-stable
|
70
78
|
${{ runner.os }}-npm-
|
71
79
|
- run: yarn install
|
72
80
|
- name: bundle install
|
73
81
|
run: |
|
74
|
-
bundle config path vendor/bundle
|
82
|
+
bundle config path $PWD/vendor/bundle
|
75
83
|
bundle install --jobs 4 --retry 3
|
76
84
|
bundle clean
|
77
85
|
- run: ${{ matrix.combo.command || 'bin/rake rspec' }}
|
data/CHANGELOG.md
CHANGED
@@ -15,7 +15,18 @@ Changes are grouped as follows:
|
|
15
15
|
|
16
16
|
|
17
17
|
|
18
|
-
## [1.0.
|
18
|
+
## [1.0.5](https://github.com/opal/opal/compare/v1.0.4...1.0.5) - 2020-12-24
|
19
|
+
|
20
|
+
|
21
|
+
### Fixed
|
22
|
+
|
23
|
+
- [Backported] Add --rbrequire (-q) option to opal cmdline tool ([#2120](https://github.com/opal/opal/pull/2120))
|
24
|
+
- Improved the --help descriptions
|
25
|
+
|
26
|
+
|
27
|
+
|
28
|
+
|
29
|
+
## [1.0.4](https://github.com/opal/opal/compare/v1.0.3...v1.0.4) - 2020-12-13
|
19
30
|
|
20
31
|
|
21
32
|
### Fixed
|
data/UNRELEASED.md
CHANGED
data/lib/opal/cli.rb
CHANGED
@@ -7,7 +7,7 @@ require 'opal/cli_runners'
|
|
7
7
|
module Opal
|
8
8
|
class CLI
|
9
9
|
attr_reader :options, :file, :compiler_options, :evals, :load_paths, :argv,
|
10
|
-
:output, :requires, :gems, :stubs, :verbose, :runner_options,
|
10
|
+
:output, :requires, :rbrequires, :gems, :stubs, :verbose, :runner_options,
|
11
11
|
:preload, :filename, :debug, :no_exit, :lib_only, :missing_require_severity
|
12
12
|
|
13
13
|
class << self
|
@@ -37,6 +37,7 @@ module Opal
|
|
37
37
|
@debug = options.delete(:debug) { false }
|
38
38
|
@filename = options.delete(:filename) { @file && @file.path }
|
39
39
|
@requires = options.delete(:requires) { [] }
|
40
|
+
@rbrequires = options.delete(:rbrequires) { [] }
|
40
41
|
|
41
42
|
@missing_require_severity = options.delete(:missing_require_severity) { Opal::Config.missing_require_severity }
|
42
43
|
|
@@ -79,6 +80,8 @@ module Opal
|
|
79
80
|
end
|
80
81
|
|
81
82
|
def create_builder
|
83
|
+
rbrequires.each(&Kernel.method(:require))
|
84
|
+
|
82
85
|
builder = Opal::Builder.new(
|
83
86
|
stubs: stubs,
|
84
87
|
compiler_options: compiler_options,
|
data/lib/opal/cli_options.rb
CHANGED
@@ -58,6 +58,13 @@ module Opal
|
|
58
58
|
options[:requires] << library
|
59
59
|
end
|
60
60
|
|
61
|
+
on('-q', '--rbrequire LIBRARY', String,
|
62
|
+
'Require the library in Ruby context before compiling'
|
63
|
+
) do |library|
|
64
|
+
options[:rbrequires] ||= []
|
65
|
+
options[:rbrequires] << library
|
66
|
+
end
|
67
|
+
|
61
68
|
on('-s', '--stub FILE', String, 'Stubbed files will be compiled as empty files') do |stub|
|
62
69
|
options[:stubs] ||= []
|
63
70
|
options[:stubs] << stub
|
@@ -105,11 +112,11 @@ module Opal
|
|
105
112
|
|
106
113
|
section 'Compilation Options:'
|
107
114
|
|
108
|
-
on('-M', '--no-method-missing', '
|
115
|
+
on('-M', '--no-method-missing', 'Disable method missing') do
|
109
116
|
options[:method_missing] = false
|
110
117
|
end
|
111
118
|
|
112
|
-
on('-O', '--no-opal', '
|
119
|
+
on('-O', '--no-opal', 'Disable implicit `require "opal"`') do
|
113
120
|
options[:skip_opal_require] = true
|
114
121
|
end
|
115
122
|
|
@@ -137,7 +144,7 @@ module Opal
|
|
137
144
|
options[:missing_require_severity] = level.to_sym
|
138
145
|
end
|
139
146
|
|
140
|
-
on('-P', '--map FILE', '
|
147
|
+
on('-P', '--map FILE', 'Output path to FILE') do |file|
|
141
148
|
options[:runner_options] ||= {}
|
142
149
|
options[:runner_options][:map_file] = file
|
143
150
|
end
|
data/lib/opal/version.rb
CHANGED
data/opal/corelib/constants.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
RUBY_PLATFORM = 'opal'
|
2
2
|
RUBY_ENGINE = 'opal'
|
3
3
|
RUBY_VERSION = '2.5.8'
|
4
|
-
RUBY_ENGINE_VERSION = '1.0.
|
5
|
-
RUBY_RELEASE_DATE = '2020-12-
|
4
|
+
RUBY_ENGINE_VERSION = '1.0.5'
|
5
|
+
RUBY_RELEASE_DATE = '2020-12-24'
|
6
6
|
RUBY_PATCHLEVEL = 0
|
7
7
|
RUBY_REVISION = 0
|
8
8
|
RUBY_COPYRIGHT = 'opal - Copyright (C) 2013-2020 Adam Beynon and the Opal contributors'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elia Schito
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2020-12-
|
13
|
+
date: 2020-12-23 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: ast
|
@@ -740,10 +740,10 @@ licenses:
|
|
740
740
|
- MIT
|
741
741
|
metadata:
|
742
742
|
bug_tracker_uri: https://github.com/opal/opal/issues
|
743
|
-
changelog_uri: https://github.com/opal/opal/blob/v1.0.
|
744
|
-
readme_uri: https://github.com/opal/opal/blob/v1.0.
|
745
|
-
api_documentation_uri: http://opalrb.com/docs/api/v1.0.
|
746
|
-
guides_uri: http://opalrb.com/docs/guides/v1.0.
|
743
|
+
changelog_uri: https://github.com/opal/opal/blob/v1.0.5/CHANGELOG.md
|
744
|
+
readme_uri: https://github.com/opal/opal/blob/v1.0.5/README.md
|
745
|
+
api_documentation_uri: http://opalrb.com/docs/api/v1.0.5/index.html
|
746
|
+
guides_uri: http://opalrb.com/docs/guides/v1.0.5/index.html
|
747
747
|
homepage_uri: https://opalrb.com/
|
748
748
|
chat_uri: https://gitter.im/opal/opal
|
749
749
|
source_code_uri: https://github.com/opal/opal
|