Undo changes to Sprockets::UglifierWithSourceMapsCompressor (#19261)
This commit is contained in:
parent
784afdf41e
commit
1e1064de0b
2 changed files with 6 additions and 11 deletions
13
.github/workflows/ci-cd.yml
vendored
13
.github/workflows/ci-cd.yml
vendored
|
|
@ -254,6 +254,8 @@ jobs:
|
|||
needs: [bundle_install, yarn_install, precompile_assets]
|
||||
timeout-minutes: 20
|
||||
env:
|
||||
RAILS_ENV: production
|
||||
NODE_ENV: production
|
||||
DATABASE_URL: postgres://postgres:postgres@localhost:5432/Forem_prod_test
|
||||
DATABASE_NAME: Forem_prod_test
|
||||
APP_PROTOCOL: http://
|
||||
|
|
@ -277,15 +279,6 @@ jobs:
|
|||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Cache compiled assets
|
||||
uses: actions/cache/@v3
|
||||
with:
|
||||
path: |
|
||||
public/assets
|
||||
public/packs-test
|
||||
tmp/cache/webpacker
|
||||
key: ${{ runner.os }}-precompiled-assets-${{ hashFiles('app/assets/**', 'app/javascript/**', 'config/webpack/**', 'config/webpacker.yml', '**/package.json', '**/yarn.lock') }}
|
||||
restore-keys: ${{ runner.os }}-precompiled-assets-
|
||||
- name: Restore node_modules
|
||||
uses: actions/cache/restore@v3
|
||||
with:
|
||||
|
|
@ -301,7 +294,7 @@ jobs:
|
|||
with:
|
||||
bundler-cache: true
|
||||
- run: bundle exec rails assets:precompile
|
||||
- run: bin/test-console-check
|
||||
- run: RAILS_ENV=test bin/test-console-check
|
||||
|
||||
cypress:
|
||||
runs-on: ubuntu-latest
|
||||
|
|
|
|||
|
|
@ -21,7 +21,9 @@ module Sprockets
|
|||
::Rails.application.config.assets.prefix,
|
||||
"#{name}-#{digest(sourcemap_json)}.js.map",
|
||||
)
|
||||
sourcemap_path = ::Rails.public_path.join(sourcemap_filename)
|
||||
# rubocop:disable Rails/RootPathnameMethods
|
||||
sourcemap_path = File.join(::Rails.public_path, sourcemap_filename)
|
||||
# rubocop:enable Rails/RootPathnameMethods
|
||||
sourcemap_url = filename_to_url(sourcemap_filename)
|
||||
|
||||
FileUtils.mkdir_p File.dirname(sourcemap_path)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue