{ "name": "ghost-monorepo", "version": "private", "private": true, "description": "The professional publishing platform", "license": "MIT", "author": "Ghost Foundation", "repository": "https://github.com/TryGhost/Ghost", "scripts": { "archive": "pnpm nx run ghost:archive", "build": "pnpm nx run-many -t build", "dev": "nx run ghost-monorepo:dev:host", "dev:docker": "export pnpm_config_enable_global_virtual_store=false GHOST_DEV_LISTEN=0.0.0.0 && pnpm install && pnpm nx run ghost-monorepo:docker:dev", "dev:mailgun": "DEV_COMPOSE_FILES='-f compose.dev.mailgun.yaml' nx run ghost-monorepo:dev:host", "dev:fake-mailgun": "DEV_COMPOSE_FILES='-f compose.dev.fake-mailgun.yaml' nx run ghost-monorepo:dev:host", "dev:fake-upgrades": "DEV_COMPOSE_FILES='-f compose.dev.fake-upgrades.yaml' nx run ghost-monorepo:dev:host", "dev:lexical": "GHOST_DEV_KOENIG_WATCH=1 nx run ghost-monorepo:dev:host:lexical", "dev:public": "nx run ghost-monorepo:dev:host:public", "dev:full": "DEV_COMPOSE_FILES='-f compose.dev.analytics.yaml -f compose.dev.storage.yaml' ANALYTICS_PROXY_TARGET=127.0.0.1:7182 ./docker/stripe/with-stripe.sh nx run ghost-monorepo:dev:host:public", "dev:analytics": "DEV_COMPOSE_FILES='-f compose.dev.analytics.yaml' ANALYTICS_PROXY_TARGET=127.0.0.1:7182 nx run ghost-monorepo:dev:host", "dev:analytics:local": "DEV_COMPOSE_FILES='-f compose.dev.analytics.yaml' ANALYTICS_PROXY_TARGET=${ANALYTICS_PROXY_TARGET:-127.0.0.1:3000} nx run ghost-monorepo:dev:host", "dev:storage": "DEV_COMPOSE_FILES='-f compose.dev.storage.yaml' nx run ghost-monorepo:dev:host", "dev:stripe": "./docker/stripe/with-stripe.sh nx run ghost-monorepo:dev:host", "dev:multi": "node tools/scripts/with-second-ghost.ts nx run ghost-monorepo:dev:host:multi", "dev:up": "node tools/gx/dev-up.ts", "dev:down": "node tools/gx/dev-down.ts", "dev:status": "node tools/gx/dev-status.ts", "dev:gc": "node tools/gx/dev-gc.ts", "fix": "pnpm store prune && node tools/scripts/clean.ts && pnpm install", "create-package": "pnpm gx generate package", "knex-migrator": "cd ghost && pnpm exec node ../tools/scripts/with-ghost-dev-env.ts env NODE_OPTIONS='--conditions=source --import=tsx' knex-migrator", "bootstrap": "pnpm install && bash tools/scripts/init-submodules.sh && (test \"$(git config --local blame.ignoreRevsFile)\" = .git-blame-ignore-revs || git config --local blame.ignoreRevsFile .git-blame-ignore-revs)", "migrate:db": "cd ghost && pnpm exec node ../tools/scripts/with-ghost-dev-env.ts env NODE_OPTIONS='--conditions=source --import=tsx' knex-migrator migrate", "rollback:db": "cd ghost && pnpm exec node ../tools/scripts/with-ghost-dev-env.ts env NODE_OPTIONS='--conditions=source --import=tsx' knex-migrator rollback", "reset:db": "cd ghost && pnpm exec node ../tools/scripts/with-ghost-dev-env.ts env NODE_OPTIONS='--conditions=source --import=tsx' sh -c 'knex-migrator reset && knex-migrator init'", "reset:db:volume": "docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev down && docker volume rm ghost-dev_mysql-data", "reset:data": "pnpm gx data generate --clear-database --quantities members:1000,posts:100 --seed 123", "reset:data:empty": "pnpm gx data generate --clear-database --quantities members:0,posts:0 --seed 123", "reset:data:xxl": "pnpm gx data generate --clear-database --quantities members:2000000,posts:0,emails:0,members_stripe_customers:0,members_login_events:0,members_status_events:0 --seed 123", "seed:multi-sub-scenarios": "pnpm gx data multi-sub-scenarios", "docker:build": "docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev build", "docker:build:verbose": "docker compose --progress=plain -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev build", "docker:clean": "docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile '*' down -v --remove-orphans --rmi local", "docker:rebase": "export pnpm_config_enable_global_virtual_store=false && git fetch ${GHOST_UPSTREAM:-origin} main && git rebase ${GHOST_UPSTREAM:-origin}/main && pnpm install && pnpm nx run-many -t build --projects=@tryghost/shade,@tryghost/admin-x-framework && docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev up -d --build --force-recreate ghost-dev", "knip": "NODE_OPTIONS=--conditions=source knip", "knip:fix": "NODE_OPTIONS=--conditions=source knip --fix --allow-remove-files=false", "lint": "pnpm lint:oxlint && pnpm nx run-many -t lint lint:boundaries && pnpm lint:dependencies && pnpm lint:packages && pnpm lint:versioning && pnpm lint:docs", "lint:oxlint": "oxlint --deny-warnings", "lint:agent-guidance": "node tools/scripts/ci/check-agent-guidance.ts", "lint:agent-skills": "node tools/scripts/ci/check-agent-skill-links.ts", "lint:doc-links": "git ls-files -z '*.md' ':(exclude,glob).changeset/**' ':(exclude,glob)**/fixture/**' ':(exclude,glob)**/fixtures/**' | xargs -0 remark --use remark-validate-links --frail --quiet", "lint:markdown": "git ls-files -z '*.md' ':(exclude,glob).changeset/**' ':(exclude,glob)**/fixture/**' ':(exclude,glob)**/fixtures/**' | xargs -0 markdownlint-cli2 --config .markdownlint-cli2.jsonc", "lint:boundaries": "node tools/scripts/ci/check-boundaries.ts", "lint:dependencies": "NODE_OPTIONS=--conditions=source knip --dependencies --treat-config-hints-as-errors", "lint:legacy-services": "node tools/scripts/ci/check-legacy-services.ts", "lint:packages": "node tools/scripts/ci/check-internal-packages.ts", "lint:versioning": "node tools/scripts/ci/check-versioning-ignore.ts", "lint:docs": "pnpm lint:agent-skills && pnpm lint:agent-guidance && pnpm lint:markdown && pnpm lint:doc-links", "format": "node tools/scripts/format.ts", "format:check": "oxfmt --check", "check": "pnpm format:check && pnpm lint && pnpm test", "test": "pnpm nx run-many -t test:unit test:types", "test:types": "pnpm nx run-many -t test:types", "test:unit": "pnpm nx run-many -t test:unit", "test:watch": "vitest", "test:e2e": "pnpm --filter @tryghost/e2e test", "test:e2e:analytics": "pnpm --filter @tryghost/e2e test:analytics", "test:e2e:all": "pnpm --filter @tryghost/e2e test:all", "test:e2e:debug": "DEBUG=@tryghost/e2e:* pnpm test:e2e", "main": "pnpm main:monorepo && pnpm main:submodules", "main:monorepo": "git checkout main && git pull ${GHOST_UPSTREAM:-origin} main && pnpm install", "main:submodules": "git submodule sync && git submodule update && git submodule foreach \"git checkout main && git pull ${GHOST_UPSTREAM:-origin} main\"", "preinstall": "node ./tools/scripts/enforce-package-manager.ts", "prepare": "husky .github/hooks", "query-parameter-policy:export": "pnpm --filter ghost query-parameter-policy:export", "tb": "docker compose -f compose.dev.yaml -f compose.dev.analytics.yaml run --rm --no-deps --entrypoint tb tb-cli --local", "tb:test": "pnpm tb test run", "data:analytics:generate": "node tools/scripts/with-ghost-dev-env.ts node ghost/core/server/data/tinybird/scripts/docker-analytics-manager.js generate", "data:analytics:clear": "node tools/scripts/with-ghost-dev-env.ts node ghost/core/server/data/tinybird/scripts/docker-analytics-manager.js clear", "release": "node tools/scripts/release/release.ts", "inventory:typescript": "node tools/scripts/ci/typescript-inventory.ts", "gx": "node tools/gx/cli.ts" }, "devDependencies": { "@playwright/test": "catalog:", "@secretlint/secretlint-rule-pattern": "catalog:", "@secretlint/secretlint-rule-preset-recommend": "catalog:", "dependency-cruiser": "catalog:", "eslint": "catalog:", "husky": "9.1.7", "knip": "catalog:", "lint-staged": "catalog:", "markdownlint-cli2": "catalog:", "nx": "24.0.5", "oxfmt": "catalog:", "oxlint": "catalog:", "remark-cli": "catalog:", "remark-validate-links": "catalog:", "secretlint": "catalog:", "shell-quote": "catalog:", "typescript": "catalog:", "vitest": "catalog:" }, "eslintIgnore": [ "**/node_modules/**" ], "devEngines": { "runtime": { "name": "node", "version": "22.23.5", "onFail": "download" } }, "engines": { "node": "^22.23.5 || ^24.22.3" }, "packageManager": "pnpm@12.16.1+sha512.091d1dee7927575661b25dab3c2ae31cafc1c54d6b71ed6a6600cf0c1cb10434a447eae14015f1b23e2e6bedeed79df94a932e2164d2832280dce3fb32f656d1", "monorepo": { "public": false, "internalPackages": true, "repo": "https://github.com/TryGhost/Ghost", "scope": "@tryghost" }, "nx": { "includedScripts": [], "targets": { "lint:boundaries": { "executor": "nx:run-commands", "cache": true, "inputs": [ "{workspaceRoot}/.dependency-cruiser.cjs", "{workspaceRoot}/.dependency-cruiser-known-violations.json", "{workspaceRoot}/tools/scripts/ci/check-boundaries.ts", "{workspaceRoot}/tools/scripts/lib/dependency-boundaries.ts", "{workspaceRoot}/tools/configs/oxlint/legacy-services.ts", "{workspaceRoot}/tools/scripts/ci/service-dependency-resolver.mjs", "{workspaceRoot}/ghost/core/**/*", "{workspaceRoot}/ghost/package.json", "{workspaceRoot}/packages/**/*", "{workspaceRoot}/contracts/**/*", "{workspaceRoot}/koenig/**/*", "{workspaceRoot}/apps/**/*", "sharedGlobals" ], "outputs": [], "options": { "command": "node tools/scripts/ci/check-boundaries.ts" } }, "docker:up": { "executor": "nx:run-commands", "options": { "command": "if [ -n \"$CODESPACES$REMOTE_CONTAINERS\" ]; then echo 'Skipping docker compose up --force-recreate: already running inside a devcontainer, whose own compose lifecycle brought these services up.'; else docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev up -d --force-recreate --wait --quiet-pull; fi" }, "dependsOn": [ "docker:build" ] }, "docker:down": { "executor": "nx:run-commands", "options": { "command": "docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev down" } }, "docker:build": { "executor": "nx:run-commands", "options": { "command": "if [ -n \"$CODESPACES$REMOTE_CONTAINERS\" ]; then echo 'Skipping docker compose build: already running inside a devcontainer, whose own compose lifecycle built/pulled these images.'; else docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev build; fi" } }, "docker:dev": { "continuous": true, "executor": "nx:run-commands", "options": { "command": "trap 'docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev down' EXIT; docker compose -f compose.dev.yaml ${DEV_COMPOSE_FILES} --profile docker-dev logs -f" }, "dependsOn": [ "docker:up", { "target": "build:assets", "projects": [ "ghost" ] }, { "target": "dev", "projects": [ "@tryghost/admin", "@tryghost/portal" ] } ] }, "dev:env": { "executor": "nx:run-commands", "options": { "command": "node tools/scripts/ghost-dev-env.ts" } }, "infra:up": { "executor": "nx:run-commands", "options": { "command": "node tools/scripts/dev-infra-up.ts" }, "dependsOn": [ "dev:env" ] }, "dev:host": { "continuous": true, "executor": "nx:run-commands", "options": { "cwd": "ghost", "command": "node ../tools/scripts/with-ghost-dev-env.ts nodemon index.js" }, "dependsOn": [ "dev:env", "infra:up", { "target": "build:assets", "projects": [ "ghost" ] }, { "target": "dev:host", "projects": [ "@tryghost/admin" ] }, { "target": "build", "projects": [ "@tryghost/portal", "@tryghost/comments-ui", "@tryghost/signup-form", "@tryghost/sodo-search", "@tryghost/announcement-bar", "@tryghost/admin-toolbar" ] } ] }, "dev:host:multi": { "continuous": true, "executor": "nx:run-commands", "options": { "cwd": "ghost", "command": "node ../tools/scripts/dev-wait-for-ghost.ts && GHOST_DEV_BACKEND_PORT=$GHOST_DEV_BACKEND_PORT_2 node ../tools/scripts/with-ghost-dev-env.ts nodemon index.js" }, "dependsOn": [ "dev:host" ] }, "dev:host:lexical": { "continuous": true, "executor": "nx:run-commands", "options": { "cwd": "ghost", "command": "node ../tools/scripts/with-ghost-dev-env.ts nodemon index.js" }, "dependsOn": [ "dev:env", "infra:up", { "target": "build:assets", "projects": [ "ghost" ] }, { "target": "dev:host", "projects": [ "@tryghost/admin" ] }, { "target": "build", "projects": [ "@tryghost/portal", "@tryghost/comments-ui", "@tryghost/signup-form", "@tryghost/sodo-search", "@tryghost/announcement-bar", "@tryghost/admin-toolbar" ] }, { "target": "dev:integrated", "projects": [ "@tryghost/koenig-lexical" ] } ] }, "dev:host:public": { "continuous": true, "executor": "nx:run-commands", "options": { "cwd": "ghost", "command": "node ../tools/scripts/with-ghost-dev-env.ts nodemon index.js" }, "dependsOn": [ "dev:env", "infra:up", { "target": "build:assets", "projects": [ "ghost" ] }, { "target": "dev:host", "projects": [ "@tryghost/admin" ] }, { "target": "dev", "projects": [ "@tryghost/portal", "@tryghost/comments-ui", "@tryghost/signup-form", "@tryghost/sodo-search", "@tryghost/announcement-bar", "@tryghost/admin-toolbar" ] } ] } } } }