Skip to content
← Back to projects

Laravel Truss Docs

Documentation, live demo and theme builder for Laravel Truss, a database structure viewer for Laravel. Structure only, never data.

#Laravel Truss, documentation site

The documentation website for Laravel Truss, published at trussphp.com. Built with Astro + Starlight.

#Local development

npm ci
npm run dev      # http://localhost:4321
npm run build    # static output in dist/
npm run dev:local # dev against a local package checkout, see below

#The live demo

The /demo/ page runs the package's actual shipped frontend. Those assets are not committed here; a prebuild step fetches them from the public package repo (albertoarena/laravel-truss) and copies them into public/demo/assets/ (generated, gitignored). By default it pins to the latest package release; override with PACKAGE_REF (e.g. PACKAGE_REF=main npm run build).

To review a package frontend change before it is pushed or released, point the build at a local checkout instead:

PACKAGE_PATH=../laravel-truss npm run build
npm run dev:local   # the same thing for the dev server

That skips the clone entirely and stamps the build local, so its asset folder is assets-local and it can never be mistaken for a release in the output. The test suite fails while local assets are in place, telling you to run npm run copy-demo-assets to restore them.

#Deployment

Server-pull model: CI (.github/workflows/publish.yml) builds the site and publishes it to the deploy branch; the host pulls that branch over HTTPS on a cron (scripts/server-deploy.sh) and flips a current symlink. Just push to main and the site updates within a few minutes, no secrets needed. Full runbook: DEPLOYMENT.md.

New version available.