theme-check 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/theme-check.yml +2 -6
- data/CHANGELOG.md +8 -0
- data/RELEASING.md +34 -2
- data/exe/theme-check-language-server.bat +3 -0
- data/exe/theme-check.bat +3 -0
- data/lib/theme_check/check.rb +1 -1
- data/lib/theme_check/checks/space_inside_braces.rb +1 -1
- data/lib/theme_check/language_server/handler.rb +1 -1
- data/lib/theme_check/language_server/server.rb +13 -2
- data/lib/theme_check/version.rb +1 -1
- metadata +6 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28cb25e47867151bea85360a9f07667f46ea30ad90285f16cc74e85370ad39d9
|
4
|
+
data.tar.gz: 2023811dad002a72f00e2c26562ff3e6b5f2f49c748d44968fd94d1f9e72300f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f3a5339873aea7a325cbc3f3715e9166b1f7734226e3d9ac7b400f048629a514f3eec5d559c77eaf70febacda35416b8332d8d1a6ebefa1d9a34f29474a4e41d
|
7
|
+
data.tar.gz: 19eec11d1eb86188fe170bce61f884072340d848e800b2bb2b344cddf3561d60594e4f066199b7f9157b54da81ce8afebc5e6db0f3dbfbc5fac208c95d2b5ed8
|
@@ -1,10 +1,6 @@
|
|
1
1
|
name: ThemeCheck
|
2
2
|
|
3
|
-
on:
|
4
|
-
push:
|
5
|
-
branches: [ master ]
|
6
|
-
pull_request:
|
7
|
-
branches: [ master ]
|
3
|
+
on: [push]
|
8
4
|
|
9
5
|
jobs:
|
10
6
|
test:
|
@@ -36,4 +32,4 @@ jobs:
|
|
36
32
|
run: bundle exec rake
|
37
33
|
- name: Test runtime
|
38
34
|
# Testing that runtime can execute, not testing the results themselves
|
39
|
-
run: bundle exec theme-check ./test/theme | grep -q "files inspected"
|
35
|
+
run: bundle exec theme-check ./test/theme | grep -q "files inspected"
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,12 @@
|
|
1
1
|
|
2
|
+
v1.2.0 / 2021-07-15
|
3
|
+
==================
|
4
|
+
|
5
|
+
* Add Windows Support ([#364](https://github.com/shopify/theme-check/issues/364))
|
6
|
+
* Ignore empty `{{}}` in SpaceInsideBraces ([#350](https://github.com/shopify/theme-check/issues/350))
|
7
|
+
* Switch to main branch
|
8
|
+
* Minor documentation fixes
|
9
|
+
|
2
10
|
v1.1.0 / 2021-07-06
|
3
11
|
==================
|
4
12
|
|
data/RELEASING.md
CHANGED
@@ -13,7 +13,14 @@
|
|
13
13
|
|
14
14
|
4. Commit your changes and make a PR.
|
15
15
|
|
16
|
-
|
16
|
+
```bash
|
17
|
+
git checkout -b "bump/theme-check-$VERSION"
|
18
|
+
git add docs/checks CHANGELOG.md lib/theme_check/version.rb
|
19
|
+
git commit -m "Bump theme-check version to $VERSION"
|
20
|
+
hub compare "main:bump/theme-check-$VERSION"
|
21
|
+
```
|
22
|
+
|
23
|
+
5. Merge your PR to main.
|
17
24
|
|
18
25
|
6. On [Shipit](https://shipit.shopify.io/shopify/theme-check/rubygems), deploy your commit.
|
19
26
|
|
@@ -46,5 +53,30 @@
|
|
46
53
|
|
47
54
|
```bash
|
48
55
|
# shortcut if you have `hub` installed
|
49
|
-
hub compare "
|
56
|
+
hub compare "main:bump/theme-check-$VERSION"
|
57
|
+
```
|
58
|
+
|
59
|
+
## Shopify CLI Release Process
|
60
|
+
|
61
|
+
1. Release `theme-check` on RubyGems by following the steps in the previous section.
|
62
|
+
|
63
|
+
2. Update the `theme-check` version in [`shopify-cli`](https://github.com/shopify/shopify-cli)'s `Gemfile.lock` and `shopify-cli.gemspec` files.
|
64
|
+
|
65
|
+
Such as in [this PR.](https://github.com/Shopify/shopify-cli/pull/1357/files)
|
66
|
+
|
67
|
+
3. Create a branch + a commit on the [`shopify-cli`](https://github.com/Shopify/shopify-cli) repository.
|
68
|
+
|
69
|
+
```bash
|
70
|
+
VERSION=X.X.X
|
71
|
+
git checkout -b "bump/theme-check-$VERSION"
|
72
|
+
git add Gemfile.lock
|
73
|
+
git add shopify-cli.gemspec
|
74
|
+
git commit -m "Bump theme-check version to $VERSION"
|
75
|
+
```
|
76
|
+
|
77
|
+
4. Create a pull-request for those changes on the [`shopify-cli`](https://github.com/Shopify/shopify-cli) repository.
|
78
|
+
|
79
|
+
```bash
|
80
|
+
# shortcut if you have `hub` installed
|
81
|
+
hub compare "main:bump/theme-check-$VERSION"
|
50
82
|
```
|
data/exe/theme-check.bat
ADDED
data/lib/theme_check/check.rb
CHANGED
@@ -69,7 +69,7 @@ module ThemeCheck
|
|
69
69
|
end
|
70
70
|
|
71
71
|
def docs_url(path)
|
72
|
-
"https://github.com/Shopify/theme-check/blob/
|
72
|
+
"https://github.com/Shopify/theme-check/blob/main/docs/checks/#{File.basename(path, '.rb')}.md"
|
73
73
|
end
|
74
74
|
|
75
75
|
def can_disable(disableable = nil)
|
@@ -52,8 +52,19 @@ module ThemeCheck
|
|
52
52
|
response_body = JSON.dump(response)
|
53
53
|
log(JSON.pretty_generate(response)) if $DEBUG
|
54
54
|
|
55
|
-
|
56
|
-
|
55
|
+
# Because programming is fun,
|
56
|
+
#
|
57
|
+
# Ruby on Windows turns \n into \r\n. Which means that \r\n
|
58
|
+
# gets turned into \r\r\n. Which means that the protocol
|
59
|
+
# breaks on windows unless we turn STDOUT into binary mode and
|
60
|
+
# set the encoding manually (yuk!) or we do this little hack
|
61
|
+
# here and put \n which gets transformed into \r\n on windows
|
62
|
+
# only...
|
63
|
+
#
|
64
|
+
# Hours wasted: 8.
|
65
|
+
eol = Gem.win_platform? ? "\n" : "\r\n"
|
66
|
+
@out.write("Content-Length: #{response_body.bytesize}#{eol}")
|
67
|
+
@out.write(eol)
|
57
68
|
@out.write(response_body)
|
58
69
|
@out.flush
|
59
70
|
end
|
data/lib/theme_check/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: theme-check
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marc-André Cournoyer
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-07-
|
11
|
+
date: 2021-07-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: liquid
|
@@ -44,6 +44,8 @@ email:
|
|
44
44
|
executables:
|
45
45
|
- theme-check
|
46
46
|
- theme-check-language-server
|
47
|
+
- theme-check-language-server.bat
|
48
|
+
- theme-check.bat
|
47
49
|
extensions: []
|
48
50
|
extra_rdoc_files: []
|
49
51
|
files:
|
@@ -117,6 +119,8 @@ files:
|
|
117
119
|
- docs/preview.png
|
118
120
|
- exe/theme-check
|
119
121
|
- exe/theme-check-language-server
|
122
|
+
- exe/theme-check-language-server.bat
|
123
|
+
- exe/theme-check.bat
|
120
124
|
- lib/theme_check.rb
|
121
125
|
- lib/theme_check/analyzer.rb
|
122
126
|
- lib/theme_check/asset_file.rb
|