🎧 The source for my personal site. Built using 11ty (and other tools).
https://www.coryd.dev/colophon
.husky | ||
api | ||
app | ||
cli | ||
config | ||
queries | ||
scripts | ||
src | ||
.dockerignore | ||
.editorconfig | ||
.gitignore | ||
.markdownlint.json | ||
.markdownlintignore | ||
.npmrc | ||
.nvmrc | ||
.prettierignore | ||
.prettierrc | ||
bootstrap.php | ||
composer.json | ||
composer.lock | ||
Dockerfile | ||
eleventy.config.js | ||
package-lock.json | ||
package.json | ||
pint.json | ||
README.md |
coryd.dev
This is the source for my personal site built using 11ty, PHP and a number of other tools.
Local dev setup
npm run setup
This will generate the required .env
file, install dependencies and configure the CLI.
Once the CLI is installed, it is invoked by running coryd
.
Remote dev setup
npm run setup:dev
This runs setup
and generates apache
configs, commands and php extensions to install and enable on the server.
Local dev workflow
coryd run start
- Open
http://localhost:8080
This will run eleventy --watch
and the PHP cli concurrently, allowing for an environment similar to production where both static and dynamic pages are available.
CLI
coryd init
: begins a series of prompts to populate the config used bycli download
.coryd run
: presents a list of commands available to run (described below).coryd tasks
: common tasks performed using the Directus API.coryd jobs
: scripts and cron jobs that can be triggered manually.coryd run [command]
: runs the specified command immediately.coryd download
: presents prompts to download images, name them consistently and place them in the directories specified when runningcli init
.
Commands
coryd run start
: primary dev command that runswatch
andphp
concurrently.coryd run watch
: watch and update when files change without running the web server.coryd run php
: starts a PHP server for local development.coryd run build
: builds static site output.coryd run clean
: removes thedist
and.cache
folders.coryd run format
: formats JavaScript, JSON, CSS and Markdown files using Prettier, PHP files using Pint and SQL files using sql-formatter.coryd run format:sql
: formats SQL files using sql-formatter.coryd run lint:md
: lints markdown files using Markdown lint.coryd run update
: checks for dependency updates and updates 11ty.
Required environment variables
POSTGREST_URL # client + server + build
POSTGREST_API_KEY # client + server + build
MASTODON_ACCESS_TOKEN # server
MASTODON_SYNDICATION_TOKEN # server
FORWARDEMAIL_API_KEY # server
BOOK_IMPORT_TOKEN # server
WATCHING_IMPORT_TOKEN # server
TMDB_API_KEY # server
NAVIDROME_SCROBBLE_TOKEN # server
NAVIDROME_API_URL # server
NAVIDROME_API_TOKEN # server
ARTIST_IMPORT_TOKEN # server
COOLIFY_REBUILD_TOKEN # server
COOLIFY_REBUILD_URL # server
DIRECTUS_API_TOKEN # cli
GIT_REPO # build
SERVER_URL # build