GH-VARIABLE-LIST(1)
π gh-variable-list(1) β the GitHub CLI manual, bestie edition π
Okay so picture this: it's gh-variable-list(1), straight out of the GitHub CLI manual, and she's here to help you list variables. That's it. That's the gig. Let's go β¨
πΈ NAME πΈ
gh-variable-list β literally just List variables, no cap π«Ά
β¨ SYNOPSIS β¨
gh variable list [flags]
Run it, add some flags if you're feeling spicy, and the variables come pouring out. Iconic behaviour honestly π
π¦ DESCRIPTION π¦
So you wanna list variables? Say less. You can do it on one of these levels, and you pick which one:
- repository (this is the default, btw, so if you don't specify anything this is what you get π) β available to GitHub Actions runs or Dependabot in a repository
- environment β available to GitHub Actions runs for a deployment environment in a repository
- organization β available to GitHub Actions runs or Dependabot within an organization
Pick your level, get your list. Main character energy all around π
π₯ OPTIONS π₯
-e,--env <string>β list variables for an environment. string is the environment name, bestie π-q,--jq <expression>β filter JSON output using ajqexpression. Yes, the jq. She's here. Obsessed π--json <fields>β output JSON with the specified fields. You choose the fields, you get the JSON β¨-o,--org <string>β list variables for an organization. string is the org, obviously π’-t,--template <string>β format JSON output using a Go template; seegh help formattingfor the deets π
π OPTIONS INHERITED FROM PARENT COMMANDS π
-R,--repo <[HOST/]OWNER/REPO>β select another repository using the[HOST/]OWNER/REPOformat. That bracket situation is doing a lot of heavy lifting but she's slaying π«Ά
β ALIASES β
gh variable ls β same energy, shorter spelling. Use whichever, we don't gatekeep π
π JSON FIELDS π
Here's the full lineup of fields you can ask for, exactly like this:
createdAt, name, numSelectedRepos, selectedReposURL, updatedAt, value, visibility
That's seven little icons, all accounted for π
π§ EXIT CODES π§
Okay so this is the vibe check for whether things went well β memorize these fr fr:
0: Successful execution β yay! we ate π1: Error β something went sideways π2: Command canceled β you (or the universe) hit the brakes π4: Authentication required β you gotta log in first, bestie π
NOTE: Specific commands may have additional exit codes. Refer to the command's help for more information. Don't come for me, I'm just the messenger π
π SEE ALSO π
gh-variable(1) β go say hi to her, she's the parent π
And that's the page, bestie! This little masterpiece is brought to you by GitHub CLI v2.102.0, dated Oct 2026 β write that down, cite it in your group chat, whatever you need πΈβ¨π
π¦ where this page comes from
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms