Skip to content

Commit

Permalink
Fixing using dependencies manager and missing .end.dist
Browse files Browse the repository at this point in the history
  • Loading branch information
MajorTom327 committed Oct 12, 2023
1 parent 8e06a90 commit c0c0f9c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 27 deletions.
4 changes: 4 additions & 0 deletions .env.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
APP_KEY=
APP_NAME=

SESSION_SECRET=
2 changes: 2 additions & 0 deletions app/lib/env.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ export const publicEnvSchema = zod.object({
export const envSchema = zod
.object({
NODE_ENV: zod.enum(["development", "production", "test"]),
APP_NAME: zod.string().default("My App"),
APP_KEY: zod.string(),
SESSION_SECRET: zod.string().uuid(),
})
.merge(publicEnvSchema);
Expand Down
27 changes: 0 additions & 27 deletions remix.init/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,21 +57,6 @@ updates:

await inquirer
.prompt([
{
type: "list",
name: "dependenciesManager",
message: "Which dependencies manager do you want to use?",
choices: ["yarn", "npm"],
when: always(packageManager === "yarn"),
loop: true,
},
{
type: "confirm",
name: "updateDependencies",
message: "Update all dependencies?",
default: true,
when: (answers) => answers.dependenciesManager === "yarn",
},
{
type: "confirm",
name: "dependabot",
Expand Down Expand Up @@ -248,18 +233,6 @@ updates:
});
};

if (answers.dependenciesManager === "yarn") {
spinner.text = "Installing dependencies with yarn";

fs.unlinkSync(path.resolve(cwd, "package-lock.json"));
await execAsync("yarn import");

if (answers.updateDependencies) {
spinner.text = "Updating dependencies";
await execAsync("yarn upgrade --latest");
}
}

// ! This should be the last step as we git-add all the files
// Configure git
if (answers.git) {
Expand Down

0 comments on commit c0c0f9c

Please sign in to comment.