Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Secretz is a management tool that lets you manage your GitHub repository secrets from the command line.

License

Notifications You must be signed in to change notification settings

anthonyb8/secretz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔐 Secretz

Secretz is a CLI tool that simplifies GitHub repository secret management. It streamlines working with GitHub secrets by letting you:

  • Create new secrets
  • Update existing ones
  • Delete unwanted secrets
  • Most importantly, upload entire .env files at once

No more manually setting secrets one by one. Secretz handles bulk operations so you can manage your repository secrets efficiently.

✨ Features

  • Bulk upload from .env files - Upload dozens of secrets in one command
  • Full CRUD operations - Create, read, update, and delete secrets
  • Clean, intuitive CLI - Simple subcommand structure
  • Direct GitHub API integration - Works with GitHub's REST API
  • Multi-repository support - Manage secrets across different repos

🚀 Quick Start

# List all secrets for a repo
secretz list -o username -r repository

# Upload secrets from .env file
secretz create -f .env -o username -r myproject

# Create a single secret
secretz create -s SECRET_NAME -v value -o username -r myproject

# Delete a secret
secretz delete -s SECRET_NAME -o username -r myproject

📋 Installation

curl -sSfL https://raw.githubusercontent.com/anthonyb8/secretz/main/scripts/install.sh | bash

🔧 Usage

All commands require the owner (-o) and repository (-r) flags to identify the target repository.

List Secrets

List the secrets on a repository

secretz list -o <OWNER> -r <REPO_NAME>

Get secret by name, best way to check if exists

secretz list -s <SECRET_NAME> -o <OWNER> -r <REPO_NAME>

Get Secret

Get secret by name, best way to check if exists

secretz get -s <SECRET_NAME> -o <OWNER> -r <REPO_NAME>

Create/Update Secret

Create or update secret

secretz create -s <SECRET_NAME> -v <SECRET_VALUE> -o <OWNER> -r <REPO_NAME>

Upload from .env File

Uploads secrets from a .env file. If no path checks current directory for .env

secretz create -f <OPTIONAL_FILE_PATH> -o <OWNER> -r <REPO_NAME>

Delete Secret

Delete secret

secretz delete -s <SECRET_NAME> -o <OWNER> -r <REPO_NAME>

The .env file should contain key=value pairs, comments will be ignored:

# comment
API_KEY=abc123
DATABASE_URL="postgres://localhost/mydb"
SECRET_TOKEN=xyz789

🔑 Authentication

Secretz requires a GitHub personal access token with repo permissions. Set it as:

export GITHUB_PAT=your_token_here

📝 License

This project is licensed under the Apache 2.0 License. See the LICENSE file for details.

About

Secretz is a management tool that lets you manage your GitHub repository secrets from the command line.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published