Logotipo Hedhog

Get Hedhog updates in your inbox

New releases, fresh recipes, and breaking changes — no spam.

hedhog new

Creates a new HedHog project from the official template.

Usage

hedhog new <project-name> [options]

What it does

Running hedhog new follows this order:

  • Clones the official template into a new folder named after the project
  • Configures the initial project environment
  • Prepares the database via Docker Compose when the default flow requires it
  • Initializes a Git repository in the created folder
  • Adds the HedHog core library to the project

Options

FlagDescription
-v, --verboseShows detailed logs
-f, --forceOverwrites an existing folder with the same name
-s, --skip-installSkips dependency installation
-h, --dbhost <name>Database host
-p, --dbport <number>Database port
-u, --dbuser <name>Database user
-w, --dbpassword <password>Database password (required — the process stops if omitted)
-d, --dbname <name>Database name
-t, --dbtype <type>Database type; the current flow is focused on Postgres

Examples

Create a new project

hedhog new my-project

Overwrite an existing folder

hedhog new my-project --force

Skip dependency installation

hedhog new my-project --skip-install

Provide database parameters

hedhog new my-project -h localhost -p 5432 -u postgres -w password -d my_database -t postgres

After creating the project

When the command finishes, enter the project folder and continue the flow:

cd my-project

From there, you can use hedhog add to include new features and hedhog update to keep libraries up to date.

# 1. Create the project
hedhog new my-project

# 2. Enter the folder
cd my-project

# 3. Add a module
hedhog add menu

# 4. Start the environment
hedhog start

Maintenance operations

CommandPurpose
hedhog dev doctorChecks hedhog.json consistency
hedhog dev doctor --fixAutomatically fixes detected inconsistencies
hedhog dev backupdbBacks up the database before risky operations
hedhog dev restoredbRestores a previous database backup

Safe update flow

hedhog dev backupdb
hedhog update          # or: hedhog update <library>
# validate the application
# if something goes wrong:
hedhog dev restoredb

Notes

  • If the folder already exists, use --force to remove and recreate it.
  • The command depends on pnpm and may initialize the database via Docker Compose.
  • Before scaffolding, hedhog new also checks for git and pnpm. When either is missing, it offers to install them automatically (interactive prompt only). See Common Installation Issues for how the winget/npm auto-install path works and a known winget/msstore failure case.
  • For the complete post-installation flow, including how to start the generated project, see Getting Started.