mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 10:20:58 -06:00
22 lines
594 B
Plaintext
22 lines
594 B
Plaintext
|
#!/usr/bin/env ruby
|
||
|
# frozen_string_literal: true
|
||
|
|
||
|
require "fileutils"
|
||
|
|
||
|
# rubocop:disable Discourse/NoChdir
|
||
|
Dir.chdir("#{__dir__}/../app/assets/javascripts") do
|
||
|
FileUtils.mv("yarn.lock", "yarn.lock-tmp")
|
||
|
FileUtils.mv("package.json", "package.json-tmp")
|
||
|
|
||
|
File.symlink("package-ember5.json", "package.json")
|
||
|
File.symlink("yarn-ember5.lock", "yarn.lock")
|
||
|
|
||
|
system "yarn install", exception: true
|
||
|
|
||
|
FileUtils.rm("yarn-ember5.lock")
|
||
|
FileUtils.cp("yarn-ember3.lock", "yarn-ember5.lock")
|
||
|
|
||
|
FileUtils.mv("yarn.lock-tmp", "yarn.lock")
|
||
|
FileUtils.mv("package.json-tmp", "package.json")
|
||
|
end
|