discourse/script/regen_ember_3_lockfile

17 lines
431 B
Ruby
Executable File

#!/usr/bin/env ruby
# frozen_string_literal: true
require "fileutils"
# rubocop:disable Discourse/NoChdir
Dir.chdir("#{__dir__}/../app/assets/javascripts") do
FileUtils.rm("yarn-ember3.lock")
FileUtils.cp("yarn-ember5.lock", "yarn-ember3.lock")
system("#{__dir__}/switch_ember_version", "3", exception: true)
system "yarn install", exception: true
system("#{__dir__}/switch_ember_version", "5", exception: true)
end