trmnl_preview 0.31.1 → 0.31.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b21d300476e67904c34d0187c12b11c59904e67429ead767147d24d50ca1db9d
4
- data.tar.gz: 5e77e6666b47b187f558d04c158907cc0441e90899f7e444cea1cc136a49a6cd
3
+ metadata.gz: 19c7a981cfdf1ef495dcc4aaa724fd21e111a307899062e9231ebc3b9dc5e702
4
+ data.tar.gz: f2e39cc80825f4f828cc999ca945d21076be53f0323d48ad56dda5e4249cbdb7
5
5
  SHA512:
6
- metadata.gz: eedd5d2c1275ac5f7a8dbc4767472e0dc5e1ff456ea352e3bbb6373190c0f98b04d8fe56f14cddcc8a2982ec57dd1ec21037d5a0c3d37b856c98830db5f81826
7
- data.tar.gz: 7e9e0209e2102edf63ccc05efe67ed69912b206cae2f4c8e33d8bc67b8f83349cc8b1f35e2694b3246e6179c487e15368746ebfa259495db9306361dca834559
6
+ metadata.gz: 72bce8abf4d3d92eaa82685ea0a7ae1e0ee1330526b152e589737bc5c058ef354c16f1601944a63f4e10fbb60db17b19244cb9d6dfdc19f7f1c94b07720c6ddf
7
+ data.tar.gz: 4cfdbc78ca03b8fffefe5552b82c956f3ff0bfdd96ab041c6415795b3c575634af8c1616b892233cf365467f7f186004d8c21cea74f23665d0b0c1e69e87946e
data/CHANGELOG.md CHANGED
@@ -1,6 +1,10 @@
1
1
 
2
2
  # Changelog
3
3
 
4
+ ## 0.31.2
5
+
6
+ - A transform whose `serverless_language` is not `node`, `python`, `ruby` or `php`, such as `javascript`, runs as node, as on TRMNL. Before, trmnlp looked for an interpreter by that name and failed with "No such file or directory @ rb_check_realpath_internal".
7
+
4
8
  ## 0.31.1
5
9
 
6
10
  - A view with no `.liquid` file draws the shared markup alone, as TRMNL does when a recipe keeps all of its markup in shared. Before, trmnlp drew "Missing template" there, so `trmnlp test` showed a blank screen for a recipe that draws on TRMNL. A view with no file and no shared markup still says "Missing template".
@@ -11,6 +11,8 @@ require_relative '../select_field_choices'
11
11
  module TRMNLP
12
12
  class Config
13
13
  class Plugin
14
+ TRANSFORM_LANGUAGES = %w[node python ruby php].freeze
15
+
14
16
  def initialize(paths, project_config)
15
17
  @paths = paths
16
18
  @project_config = project_config
@@ -83,9 +85,12 @@ module TRMNLP
83
85
  # stores it on the plugin_setting record. The scaffold emits
84
86
  # `serverless_language: ''`, so empty strings collapse to nil here
85
87
  # to let the `||` in the pipeline fall through to the inferred value.
88
+ # TRMNL runs any other value (like `javascript`) as node.
86
89
  def serverless_language
87
90
  value = @config['serverless_language']
88
- value unless value.to_s.empty?
91
+ return if value.to_s.empty?
92
+
93
+ TRANSFORM_LANGUAGES.include?(value) ? value : 'node'
89
94
  end
90
95
 
91
96
  # The TRMNL design-system version this plugin renders against.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module TRMNLP
4
- VERSION = '0.31.1'
4
+ VERSION = '0.31.2'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trmnl_preview
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.31.1
4
+ version: 0.31.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rockwell Schrock