Skip to content

Commit

Permalink
Remove CLI defaults, update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
haydenbleasel committed Jan 14, 2025
1 parent 8a26bec commit 8259f64
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 9 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
Clone the repo using:

```sh
npx next-forge@latest init [my-app]
npx next-forge@latest init
```

Then read the [docs](https://docs.next-forge.com) for more information.
Expand Down
15 changes: 11 additions & 4 deletions docs/setup/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,23 @@ description: How to setup, install and run next-forge.

## Initialization

Run the `next-forge` init command, replacing `[my-app]` with your project name.
Run the `next-forge` init command:

```sh Terminal
npx next-forge@latest init [my-app]
npx next-forge@latest init
```

You can also specify the package manager to use with the `package-manager` option, e.g.
You will be prompted for the project name and package manager.

```sh Terminal
npx next-forge@latest init [my-app] --package-manager bun
$ npx next-forge@latest init

? What is your project named?
? What package manager do you want to use? (Use arrow keys)
❯ pnpm
npm
yarn
bun
```

This will create a new directory with your project name and clone the repo into it. It will run a setup script to install dependencies and copy `.env` files. You can read more about environment variables [here](/setup/env).
Expand Down
5 changes: 2 additions & 3 deletions scripts/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@ import { update } from './update.mjs';
program
.command('init')
.description('Initialize a new next-forge project')
.option('--name <name>', 'Name of the project', 'next-forge')
.option('--name <name>', 'Name of the project')
.option(
'--package-manager <manager>',
'Package manager to use (npm, yarn, bun, pnpm)',
'pnpm'
'Package manager to use (npm, yarn, bun, pnpm)'
)
.option('--disable-git', 'Disable git initialization')
.action(initialize);
Expand Down
2 changes: 1 addition & 1 deletion splash/app/components/installer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import { CopyIcon } from 'lucide-react';
import { toast } from 'sonner';

const command = 'npx next-forge@latest init [my-app]';
const command = 'npx next-forge@latest init';

export const Installer = () => {
const handleCopy = () => {
Expand Down

0 comments on commit 8259f64

Please sign in to comment.