asset_sync 2.18.0 → 2.18.1

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: b64084370fbccba4e315b80d8877893f7e556fc24eecc938f1dda2a328a78e3b
4
- data.tar.gz: f387731557d333a5d295c4c62ac9fedc3d6b23c57509f1cefb306d823d91845e
3
+ metadata.gz: 1fb2743cc1cc656c27c392c0a4f6cd5cc07e57ed8dad28fc1ed9f01b268d6d42
4
+ data.tar.gz: 13067af05b7e16f1a12c62db2583f56ec5e995414d86e193110339efde7f8e16
5
5
  SHA512:
6
- metadata.gz: f64ebb5f182457d6010c0c2c5ad8535668f980594c8d59bc7c59838d105e64d2ae7c067dca99604bca9e1dacccd2dedc5104cc88cedd2dfc7679aab7ebbe0d22
7
- data.tar.gz: 87bf1e02addf61a30abfddd4ea082f2d730db5428425d2676808624349d3f2f987967051a85b9d075155e1555dbdfe3dcd34ab2d18580e39d272280d1436596f
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.17.0...HEAD
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
  [![Gem Version](https://img.shields.io/gem/v/asset_sync.svg?style=flat-square)](http://badge.fury.io/rb/asset_sync)
3
- [![Tests](https://github.com/AssetSync/asset_sync/actions/workflows/tests.yaml/badge.svg)](https://github.com/AssetSync/asset_sync/actions/workflows/tests.yaml)
3
+ [![GitHub Build Status](https://img.shields.io/github/actions/workflow/status/AssetSync/asset_sync/tests.yaml?branch=master&style=flat-square)](https://github.com/AssetSync/asset_sync/actions/workflows/tests.yaml)
4
4
  [![Coverage Status](http://img.shields.io/coveralls/AssetSync/asset_sync.svg?style=flat-square)](https://coveralls.io/r/AssetSync/asset_sync)
5
5
 
6
6
 
@@ -117,9 +117,13 @@ module AssetSync
117
117
  end
118
118
 
119
119
  def manifest_path
120
- directory =
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
- File.join(directory, "manifest.yml")
125
+ File.join(directory, "manifest.yml")
126
+ end
123
127
  end
124
128
 
125
129
  def gzip?
@@ -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}"
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AssetSync
4
- VERSION = "2.18.0"
4
+ VERSION = "2.18.1"
5
5
  end
@@ -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.0
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-01-30 00:00:00.000000000 Z
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.5
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