# THIS IS AUTOGENERATED. DO NOT EDIT MANUALLY
version = 1
name = "thingtime"

[setup]
script = '''
#!/usr/bin/env bash
set -euo pipefail

if ! command -v gh >/dev/null 2>&1; then
  echo "gh CLI is not installed"
  exit 1
fi

if [ -z "${GH_TOKEN:-}" ]; then
  echo "GH_TOKEN is not set"
  exit 1
fi

# Authenticate gh without printing the token.
printf '%s' "$GH_TOKEN" | gh auth login --hostname github.com --with-token

# Configure git push/fetch auth through gh.
gh auth setup-git --hostname github.com

# Optional but useful for commits created by Codex.
git config --global user.name "${GIT_AUTHOR_NAME:-Codex}"
git config --global user.email "${GIT_AUTHOR_EMAIL:-codex@users.noreply.github.com}"

# Quick verification without exposing secrets.
gh auth status --hostname github.com
'''
