snippetbashTip
gh secret set — Create or update GitHub secrets. More information: <https://cli.github.com/manual/gh_secret_set>.
Viewed 0 times
createcommandupdategithubclimoregh secret setsecrets
Problem
How to use the
gh secret set command: Create or update GitHub secrets. More information: <https://cli.github.com/manual/gh_secret_set>.Solution
gh secret set — Create or update GitHub secrets. More information: <https://cli.github.com/manual/gh_secret_set>.Set a secret for the current repository (user will be prompted for the value):
gh secret set {{name}}Set a secret from a file for the current repository:
gh < {{path/to/file}} secret set {{name}}Set a secret for a specific repository:
gh secret set {{name}} {{[-b|--body]}} {{value}} {{[-R|--repo]}} {{owner}}/{{repository}}Set an organization secret for specific repositories:
gh secret set {{name}} {{[-o|--org]}} {{organization}} {{[-r|--repos]}} "{{repository1,repository2,...}}"Set an organization secret with a specific visibility:
gh secret set {{name}} {{[-o|--org]}} {{organization}} {{[-v|--visibility]}} {{all|private|selected}}Code Snippets
Set a secret for the current repository (user will be prompted for the value)
gh secret set {{name}}Set a secret from a file for the current repository
gh < {{path/to/file}} secret set {{name}}Set a secret for a specific repository
gh secret set {{name}} {{[-b|--body]}} {{value}} {{[-R|--repo]}} {{owner}}/{{repository}}Set an organization secret for specific repositories
gh secret set {{name}} {{[-o|--org]}} {{organization}} {{[-r|--repos]}} "{{repository1,repository2,...}}"Set an organization secret with a specific visibility
gh secret set {{name}} {{[-o|--org]}} {{organization}} {{[-v|--visibility]}} {{all|private|selected}}Context
tldr-pages: common/gh secret set
Revisions (0)
No revisions yet.