File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -151,14 +151,16 @@ setup: install-hooks
151151 @echo " Setup complete."
152152
153153# Create or promote admin user
154- # Usage : make create-admin EMAIL=admin @example.com PASSWORD=securepass
155- # Optional: make create-admin EMAIL=admin@example.com PASSWORD=securepass NAME="Admin"
154+ # Promote existing user : make create-admin EMAIL=user @example.com
155+ # Create new admin: make create-admin EMAIL=admin@example.com PASSWORD=securepass NAME="Admin"
156156create-admin :
157- @if [ -z " $( EMAIL) " ] || [ -z " $( PASSWORD) " ]; then \
158- echo " Error: EMAIL and PASSWORD are required. Usage: make create-admin EMAIL=admin@example.com PASSWORD=securepass" ; \
157+ @if [ -z " $( EMAIL) " ]; then \
158+ echo " Error: EMAIL is required." ; \
159+ echo " Promote existing user: make create-admin EMAIL=user@example.com" ; \
160+ echo " Create new admin: make create-admin EMAIL=admin@example.com PASSWORD=securepass" ; \
159161 exit 1; \
160162 fi
161- docker-compose exec backend uv run python -m scripts.create_admin --email $(EMAIL ) --password $(PASSWORD ) $(if $(NAME ) ,--name "$(NAME ) ")
163+ docker-compose exec backend uv run python -m scripts.create_admin --email $(EMAIL ) $( if $( PASSWORD ) , --password $(PASSWORD ) ) $(if $(NAME ) ,--name "$(NAME ) ")
162164
163165# Show running containers
164166ps :
You can’t perform that action at this time.
0 commit comments