From 5a886307fd3295f4da4b551c74f62770a6254c5d Mon Sep 17 00:00:00 2001 From: Oleks Date: Mon, 11 May 2026 17:14:35 +0300 Subject: [PATCH] chore(ddev): add build-gitea-frontend command `make backend` embeds public/ via go:embed at compile time, so any frontend asset change requires: ddev build-gitea-frontend # vite into public/assets/ ddev build-gitea # re-embed public/ into the binary ddev restart # pick up new binary --- .ddev/.gitignore | 1 + .ddev/commands/web/build-gitea-frontend | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100755 .ddev/commands/web/build-gitea-frontend diff --git a/.ddev/.gitignore b/.ddev/.gitignore index 643d6148b9..40eedf0522 100644 --- a/.ddev/.gitignore +++ b/.ddev/.gitignore @@ -11,6 +11,7 @@ commands/* !commands/web/ commands/web/* !commands/web/build-gitea +!commands/web/build-gitea-frontend !gitea/ gitea/* !gitea/app.ini diff --git a/.ddev/commands/web/build-gitea-frontend b/.ddev/commands/web/build-gitea-frontend new file mode 100755 index 0000000000..bc0f682365 --- /dev/null +++ b/.ddev/commands/web/build-gitea-frontend @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +## Description: Build the gitea frontend assets (CSS/JS) inside the web container +## Usage: build-gitea-frontend +## Example: ddev build-gitea-frontend + +set -eu +cd /var/www/html +echo "Installing frontend deps and building assets..." +make deps-frontend +make frontend +echo "Done."