discourse_theme 2.1.2 → 2.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7c952dc0bc427d1c7a5e928ea8140735aa5cdbb4b6d0af282b4660399f201720
4
- data.tar.gz: 98e0fbc726922cab037dd90ae1683e36ec742b209e0604ef34ec09cd751a9010
3
+ metadata.gz: e7b8d105b14bd38cbfec08a6a7f0e77245dbfdcd4d311c9589aed4e039ba4e91
4
+ data.tar.gz: d444c4ccf8343f5a7aeb3c6a5b6ab981108d12d71cdabc1a9604a30414c6be3f
5
5
  SHA512:
6
- metadata.gz: 4b9d6671a41ed236124203d96582f487cc85daabf002d00c7f50b69ff0a769b1750e3ad07eee216dc887bb74b0b48509287bb675854a2bafef06a9a9f7c9dc76
7
- data.tar.gz: 37d80cea940d2e30b2a7452fe9a6916dcae39701b744a1a7041e7c9de1953c200ab23d3a4a47c940e2fe65bcd0defe8849bbb896680ab0b543dccb85b563b283
6
+ metadata.gz: 853e252824cb6274a18cf813bdd344065a8154704c6a25b9261c9fcb3f74e0394a64a6a2de8511d995dd8b5d2d7269b58af521aa4bf46544a4facf336ef84748
7
+ data.tar.gz: 46857c696793e4c6be343f383e773698745d68ef34971147630e6f070c6c2c406fbd0cc57c44612abf7fb41d83d595be6912b6276a375f22ad3f6eda73ddaf00
@@ -45,6 +45,9 @@ jobs:
45
45
  git config --global user.email "ci@ci.invalid"
46
46
  git config --global user.name "Discourse CI"
47
47
 
48
+ - name: Install pnpm
49
+ run: npm install -g pnpm
50
+
48
51
  - name: Setup ruby
49
52
  uses: ruby/setup-ruby@v1
50
53
  with:
data/CHANGELOG.md CHANGED
@@ -5,7 +5,13 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
- ## [2.1.1] - 2024-03-25
8
+ ## [2.1.3] - 2024-10-09
9
+
10
+ ### Added
11
+
12
+ - Made `new` command compatible with the replacement of `yarn` with `pnpm` as a package manager, and will prompt users to install `pnpm` if not installed already.
13
+
14
+ ## [2.1.2] - 2024-04-16
9
15
 
10
16
  ### Added
11
17
 
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  lib = File.expand_path("../lib", __FILE__)
4
- $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ $LOAD_PATH.unshift(lib) if !$LOAD_PATH.include?(lib)
5
5
  require "discourse_theme/version"
6
6
 
7
7
  Gem::Specification.new do |spec|
@@ -36,7 +36,7 @@ Gem::Specification.new do |spec|
36
36
  spec.add_development_dependency "guard"
37
37
  spec.add_development_dependency "guard-minitest"
38
38
  spec.add_development_dependency "webmock"
39
- spec.add_development_dependency "rubocop-discourse", "~> 3.6.0"
39
+ spec.add_development_dependency "rubocop-discourse", "~> 3.8.1"
40
40
  spec.add_development_dependency "m"
41
41
  spec.add_development_dependency "syntax_tree"
42
42
  spec.add_development_dependency "mocha"
@@ -61,6 +61,7 @@ module DiscourseTheme
61
61
  end
62
62
  raise DiscourseTheme::ThemeError.new "git is not installed" if !command?("git")
63
63
  raise DiscourseTheme::ThemeError.new "yarn is not installed" if !command?("yarn")
64
+ raise DiscourseTheme::ThemeError.new "pnpm is not installed" if !command?("pnpm")
64
65
 
65
66
  DiscourseTheme::Scaffold.generate(dir, name: args[1])
66
67
  watch_theme?(args)
@@ -65,7 +65,14 @@ module DiscourseTheme
65
65
  exception: true
66
66
 
67
67
  UI.info "Installing dependencies"
68
- system "yarn", exception: true
68
+ if File.exist?("yarn.lock")
69
+ system "yarn", exception: true
70
+ elsif File.exist?("pnpm-lock.yaml")
71
+ system "pnpm", "install", exception: true
72
+ else
73
+ UI.warn "No lock file found. Defaulting to pnpm."
74
+ system "pnpm", "install", exception: true
75
+ end
69
76
  end
70
77
 
71
78
  puts "✅ Done!"
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module DiscourseTheme
3
- VERSION = "2.1.2"
3
+ VERSION = "2.1.4"
4
4
  end
@@ -16,7 +16,7 @@ module DiscourseTheme
16
16
 
17
17
  def watch
18
18
  listener =
19
- Listen.to(@dir) do |modified, added, removed|
19
+ Listen.to(@dir, ignore: %r{^node_modules/}) do |modified, added, removed|
20
20
  begin
21
21
  if modified.length == 1 && added.length == 0 && removed.length == 0 &&
22
22
  (resolved = resolve_file(modified[0]))
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: discourse_theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.2
4
+ version: 2.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Saffron
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-04-16 00:00:00.000000000 Z
10
+ date: 2025-01-09 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: minitar
@@ -184,14 +183,14 @@ dependencies:
184
183
  requirements:
185
184
  - - "~>"
186
185
  - !ruby/object:Gem::Version
187
- version: 3.6.0
186
+ version: 3.8.1
188
187
  type: :development
189
188
  prerelease: false
190
189
  version_requirements: !ruby/object:Gem::Requirement
191
190
  requirements:
192
191
  - - "~>"
193
192
  - !ruby/object:Gem::Version
194
- version: 3.6.0
193
+ version: 3.8.1
195
194
  - !ruby/object:Gem::Dependency
196
195
  name: m
197
196
  requirement: !ruby/object:Gem::Requirement
@@ -270,7 +269,6 @@ homepage: https://github.com/discourse/discourse_theme
270
269
  licenses:
271
270
  - MIT
272
271
  metadata: {}
273
- post_install_message:
274
272
  rdoc_options: []
275
273
  require_paths:
276
274
  - lib
@@ -285,8 +283,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
285
283
  - !ruby/object:Gem::Version
286
284
  version: '0'
287
285
  requirements: []
288
- rubygems_version: 3.5.3
289
- signing_key:
286
+ rubygems_version: 3.6.2
290
287
  specification_version: 4
291
288
  summary: CLI helper for creating Discourse themes
292
289
  test_files: []