asset_sync 2.18.0 → 2.18.1
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/CHANGELOG.md +11 -1
- data/README.md +1 -1
- data/lib/asset_sync/config.rb +6 -2
- data/lib/asset_sync/storage.rb +2 -2
- data/lib/asset_sync/version.rb +1 -1
- data/spec/unit/asset_sync_spec.rb +5 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1fb2743cc1cc656c27c392c0a4f6cd5cc07e57ed8dad28fc1ed9f01b268d6d42
|
4
|
+
data.tar.gz: 13067af05b7e16f1a12c62db2583f56ec5e995414d86e193110339efde7f8e16
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 57189c1fb4dbd6edab1f5cc262f6ef420f144631adf69d03fc504218018de8765ce15e9d8e38e19eacf4eb825d3ec46b1311cf492939fc537c30554ba26dbd99
|
7
|
+
data.tar.gz: 56eba25178ac8ee2a51222bfbd46342dc8836e67d52ea255000a710a341b158bee5043969574d111779c589f9223137a2c9a4ed9a1a259adb595ddaa9fd87b40
|
data/CHANGELOG.md
CHANGED
@@ -18,6 +18,14 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
|
18
18
|
- Nothing
|
19
19
|
|
20
20
|
|
21
|
+
## [2.18.1] - 2023-08-02
|
22
|
+
|
23
|
+
### Changed
|
24
|
+
|
25
|
+
- Respect explicitly set `Rails.application.config.assets.manifest`
|
26
|
+
(https://github.com/AssetSync/asset_sync/pull/434)
|
27
|
+
|
28
|
+
|
21
29
|
## [2.18.0] - 2023-01-30
|
22
30
|
|
23
31
|
### Added
|
@@ -1078,7 +1086,9 @@ Changes:
|
|
1078
1086
|
* Merge branch 'sinatra'
|
1079
1087
|
|
1080
1088
|
|
1081
|
-
[Unreleased]: https://github.com/AssetSync/asset_sync/compare/v2.
|
1089
|
+
[Unreleased]: https://github.com/AssetSync/asset_sync/compare/v2.18.1...HEAD
|
1090
|
+
[2.18.1]: https://github.com/AssetSync/asset_sync/compare/v2.18.0...v2.18.1
|
1091
|
+
[2.18.0]: https://github.com/AssetSync/asset_sync/compare/v2.17.0...v2.18.0
|
1082
1092
|
[2.17.0]: https://github.com/AssetSync/asset_sync/compare/v2.16.0...v2.17.0
|
1083
1093
|
[2.16.0]: https://github.com/AssetSync/asset_sync/compare/v2.15.3...v2.16.0
|
1084
1094
|
[2.15.3]: https://github.com/AssetSync/asset_sync/compare/v2.15.2...v2.15.3
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
|
2
2
|
[](http://badge.fury.io/rb/asset_sync)
|
3
|
-
[](https://github.com/AssetSync/asset_sync/actions/workflows/tests.yaml)
|
4
4
|
[](https://coveralls.io/r/AssetSync/asset_sync)
|
5
5
|
|
6
6
|
|
data/lib/asset_sync/config.rb
CHANGED
@@ -117,9 +117,13 @@ module AssetSync
|
|
117
117
|
end
|
118
118
|
|
119
119
|
def manifest_path
|
120
|
-
|
120
|
+
if defined?(ActionView) && ActionView::Base.respond_to?(:assets_manifest)
|
121
|
+
::Rails.application.config.assets.manifest
|
122
|
+
else
|
123
|
+
directory =
|
121
124
|
::Rails.application.config.assets.manifest || default_manifest_directory
|
122
|
-
|
125
|
+
File.join(directory, "manifest.yml")
|
126
|
+
end
|
123
127
|
end
|
124
128
|
|
125
129
|
def gzip?
|
data/lib/asset_sync/storage.rb
CHANGED
@@ -59,7 +59,7 @@ module AssetSync
|
|
59
59
|
return [] unless self.config.include_manifest
|
60
60
|
|
61
61
|
if ActionView::Base.respond_to?(:assets_manifest)
|
62
|
-
manifest = Sprockets::Manifest.new(ActionView::Base.assets_manifest.environment, ActionView::Base.assets_manifest.dir)
|
62
|
+
manifest = Sprockets::Manifest.new(ActionView::Base.assets_manifest.environment, ActionView::Base.assets_manifest.dir, self.config.manifest_path)
|
63
63
|
manifest_path = manifest.filename
|
64
64
|
else
|
65
65
|
manifest_path = self.config.manifest_path
|
@@ -139,7 +139,7 @@ module AssetSync
|
|
139
139
|
if self.config.manifest
|
140
140
|
if ActionView::Base.respond_to?(:assets_manifest)
|
141
141
|
log "Using: Rails 4.0 manifest access"
|
142
|
-
manifest = Sprockets::Manifest.new(ActionView::Base.assets_manifest.environment, ActionView::Base.assets_manifest.dir)
|
142
|
+
manifest = Sprockets::Manifest.new(ActionView::Base.assets_manifest.environment, ActionView::Base.assets_manifest.dir, self.config.manifest_path)
|
143
143
|
return manifest.assets.values.map { |f| File.join(self.config.assets_prefix, f) }
|
144
144
|
elsif File.exist?(self.config.manifest_path)
|
145
145
|
log "Using: Manifest #{self.config.manifest_path}"
|
data/lib/asset_sync/version.rb
CHANGED
@@ -258,6 +258,11 @@ describe AssetSync do
|
|
258
258
|
Rails.application.config.assets.prefix = 'custom_assets'
|
259
259
|
expect(AssetSync.config.manifest_path).to match(/public\/custom_assets\/manifest.yml/)
|
260
260
|
end
|
261
|
+
|
262
|
+
it "config.manifest_path should point to explicit path" do
|
263
|
+
Rails.application.config.assets.manifest = 'config/manifest.json'
|
264
|
+
expect(AssetSync.config.manifest_path).to start_with('config/manifest.json')
|
265
|
+
end
|
261
266
|
end
|
262
267
|
|
263
268
|
describe 'with cache_asset_regexps' do
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asset_sync
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.18.
|
4
|
+
version: 2.18.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Simon Hamilton
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2023-
|
14
|
+
date: 2023-08-02 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: fog-core
|
@@ -288,7 +288,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
288
288
|
- !ruby/object:Gem::Version
|
289
289
|
version: '0'
|
290
290
|
requirements: []
|
291
|
-
rubygems_version: 3.4.
|
291
|
+
rubygems_version: 3.4.17
|
292
292
|
signing_key:
|
293
293
|
specification_version: 4
|
294
294
|
summary: Synchronises Assets in a Rails 3 application and Amazon S3/Cloudfront and
|