#!/bin/sh
set -eu

username="${GITEA_USERNAME:-learning_ai_user}"
token_file="${GITEA_TOKEN_FILE:-/root/.gitea_npm_token_home}"

case "${1:-}" in
  *Username*)
    printf '%s\n' "$username"
    ;;
  *Password*)
    tr -d '\n' < "$token_file"
    ;;
  *)
    exit 1
    ;;
esac
