Skip to content
This repository has been archived by the owner on Mar 25, 2023. It is now read-only.

Commit

Permalink
In setup.sh, delete any leftover yarn release artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
milesrichardson committed Mar 15, 2021
1 parent fd6a3af commit f5b47f6
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,16 @@ dir_has_yarn_release() {
local prefixDir="$1"
shift

# Clean up old files that are deprecated and shouldn't be checked in anymore if they exist
if test -f "$prefixDir"/.yarn/releases/yarn-rc.js ; then
rm "$prefixDir"/.yarn/releases/yarn-rc.js
fi
if test -f "$prefixDir"/.yarn/releases/yarn-berry.cjs ; then
rm "$prefixDir"/.yarn/releases/yarn-berry.cjs
fi
if test -f "$prefixDir"/.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs ; then
rm "$prefixDir"/.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs
fi

if has_broken_yarn "$prefixDir" ; then
echo "yarn seems broken in $prefixDir, remove .yarnrc.yml"
Expand Down

0 comments on commit f5b47f6

Please sign in to comment.