Skip to content

Commit

Permalink
fix: yarn config get
Browse files Browse the repository at this point in the history
  • Loading branch information
lensbart authored and MichaelDeBoey committed Jun 29, 2022
1 parent 5227f2f commit 36ff8a4
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions packages/remix-dev/cli/create.ts
Original file line number Diff line number Diff line change
Expand Up @@ -205,12 +205,14 @@ export async function createApp({
if (installDeps) {
let packageManager = getPreferredPackageManager();

let npmConfig = execSync(
`${packageManager} config get @remix-run:registry`,
{
let npmConfig;
try {
npmConfig = execSync(`${packageManager} config get @remix-run:registry`, {
encoding: "utf8",
}
);
});
} catch {
// Yarn throws when it can't find a "@remix-run:registry" configuration setting
}
if (npmConfig?.startsWith("https://npm.remix.run")) {
throw Error(
"🚨 Oops! You still have the private Remix registry configured. Please " +
Expand Down

0 comments on commit 36ff8a4

Please sign in to comment.