mirror of
https://github.com/sajenim/javascript-template.git
synced 2025-12-17 03:50:40 +08:00
Restructure project to support multiple templates via Nix flakes and omnix. Users can now choose between vanilla JavaScript or Next.js TypeScript templates during initialization. - Move existing template to templates/vanilla/ - Add templates/nextjs/ with App Router, TypeScript, and React 19 - Update flake.nix for multi-template outputs - Add TypeScript support to shared devshell - Preserve FHS compatibility for both templates - Update README with comprehensive template comparison and usage
66 lines
1 KiB
Makefile
66 lines
1 KiB
Makefile
# List available commands
|
|
default:
|
|
@just --list
|
|
|
|
# Start development server with hot reload
|
|
dev:
|
|
bun run dev
|
|
|
|
# Add a package dependency
|
|
add package:
|
|
bun add {{package}}
|
|
|
|
# Add a dev dependency
|
|
add-dev package:
|
|
bun add -d {{package}}
|
|
|
|
# Remove a package dependency
|
|
remove package:
|
|
bun remove {{package}}
|
|
|
|
# Build for production
|
|
build:
|
|
bun run build
|
|
|
|
# Start production server
|
|
start:
|
|
bun run start
|
|
|
|
# Install dependencies
|
|
install:
|
|
bun install
|
|
|
|
# Update flake inputs
|
|
update:
|
|
nix flake update
|
|
|
|
# Upgrade package dependencies
|
|
upgrade:
|
|
bun update
|
|
|
|
# Clean build artifacts and dependencies
|
|
clean:
|
|
rm -rf .next node_modules bun.lockb
|
|
|
|
# Format code with prettierd
|
|
format:
|
|
prettierd --write .
|
|
|
|
# Check formatting without making changes
|
|
format-check:
|
|
prettierd --check .
|
|
|
|
# Lint code with Next.js ESLint
|
|
lint:
|
|
bun run lint
|
|
|
|
# Lint and auto-fix issues
|
|
lint-fix:
|
|
bun run lint -- --fix
|
|
|
|
# Type check with TypeScript
|
|
typecheck:
|
|
tsc --noEmit
|
|
|
|
# Check formatting, linting, and types
|
|
check: format-check lint typecheck
|