-
Create repository from template
gh repo create --clone --template castdin/quickstart-nextjs --private $projectName
-
Install dependencies
bun install
rm bun.lockb
jq '.dependencies | keys[]' package.json | xargs bun add $1
jq '.devDependencies | keys[]' package.json | xargs bun add --dev $1
-
Clone template repository
git clone git@github.com:castdin/quickstart-nextjs.git
-
Reset Git index
git rm -rf .
git clean -fxd
git reset
-
Re-create NextJS project
bunx create-next-app . --typescript --eslint --tailwind --src-dir --app --use-bun
-
Change dependencies to range versions
jq '.dependencies | keys[]' package.json | xargs bun add $1
jq '.devDependencies | keys[]' package.json | xargs bun add --dev $1
-
Sort dependencies in
package.json
bunx sort-package-json
-
Add Prettier dependencies
bun add --dev prettier eslint-config-prettier prettier-plugin-tailwindcss prettier-plugin-css-order
-
Create or update the following configuration files:
-
.editorconfig
root = true [*] indent_style = tab insert_final_newline = true trim_trailing_whitespace = true
-
.eslintrc.json
{ "extends": ["next", "prettier"] }
-
.prettierrc.json
{ "plugins": ["prettier-plugin-tailwindcss"] }
-
-
Run Prettier
bun prettier --write .