cmds.projects.CmdGetAuthInfo: Fix: echo credentials "None" #122
Loading…
Reference in a new issue
No description provided.
Delete branch "jan/fix/20260922-cmds-projects-cmdgetauthinfo-fix-echo-credentials-none"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
cmds.projects.CmdGetAuthInfo: Fix: echo credentials "None"
get-auth-info() reads the origin URL of the jw-pkg repository and reports its username and password. Uri.username and Uri.password are None for URLs without a credentials part, but _run() stored them in the result anyway, so --username --only-values printed the literal string "None" for such URLs.
The bootstrap Makefile derives JANWARE_USER from exactly that output on its second parse, after the jw-pkg directory has been cloned from an anonymous https origin whose URL has no user part. JANWARE_USER thus became the string "None", pgit.sh is invoked with --login None and --refspec None:current-branch:current-branch, and queries the Forgejo API for the repositories of a non-existent "None" org, so every anonymous bootstrap fails with "Failed to enumerate repositories".
Make _run() only record values that are not None, so missing credentials produce no output instead of the string "None".