Skip to content
Projects

adrianmg/github-pewpew has 316 GitHub stars and 15 forks. GitHot measured 0 stars in 24 hours. Last checked 2026-11-19 03:31 UTC. Last push 2026-08-22.

How these counts are measured

Measured star growth

in 24h
0
in 7 days
Collecting history
in 15 days
Collecting history
in 1 month
Collecting history

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

About

πŸ”« Pew pew needless GitHub repos from your CLI!

Developer Tools

README.md

Original

Logo
github-pewpew

Pew pew needless GitHub resources!
Clean up repositories, Codespaces, and gists from the CLI.

npm version Just for fun. No, really.


Preview of the tool

Installation and Usage

To install the latest version of github-pewpew CLI, run this command:

npm i -g github-pewpew

To quickly start using it, run the following command:

ghpew

Available commands:

ghpew repos
ghpew repos --archive
ghpew repos -a
ghpew repos --force
ghpew repos --regex '^adrianmg/demo-'
ghpew repos --list 'adrianmg/one,adrianmg/two'
ghpew repos --list 'adrianmg/one,adrianmg/two' --force
ghpew gists
ghpew codespaces
ghpew help

Repository selection is interactive by default. --regex uses a case-sensitive JavaScript regular expression against each full owner/repository name; pass the pattern without / delimiters. --list accepts exact, comma-separated owner/repository names and stops without processing anything if a name is not available. Every selection mode asks for confirmation unless --force is provided, and either filtering flag can be combined with --archive. Because --force processes the selection immediately, review it carefully first.

Codespaces and gists use interactive multi-selection and always ask for confirmation before deleting anything. Gists are identified by their description or first filename, visibility, and unique ID. Gist deletion cannot be undone. The first run after upgrading may ask you to sign in again so the CLI can request permission to manage gists.

Why?

Have you ever had too much fun with GitHub and ended up creating too many throwaway repositories, Codespaces, or gists? Me too πŸ˜…!

I made this little CLI tool to clean up GitHub clutter quickly. Let me know what you think.

Do you want to know more? Visit the official website.

Development

The important parts of the project are the following:

β”œβ”€β”€ .github                GitHub Actions workflows and repo settings
β”œβ”€β”€ src
β”‚   β”œβ”€β”€ commands
β”‚   β”‚   β”œβ”€β”€ codespaces.js  Contains the command to delete codespaces
β”‚   β”‚   β”œβ”€β”€ gists.js       Contains the command to delete gists
β”‚   β”‚   └── repos.js       Contains the command to process repositories
β”‚   β”œβ”€β”€ config.js          Contains the configuration manager
β”‚   β”œβ”€β”€ github.js          Business logic: authentication and API calls
β”‚   β”œβ”€β”€ repo-options.js    Parses and resolves repository selection options
β”‚   β”œβ”€β”€ ui.js              CLI interactions
β”‚   └── utils.js           Lightweight utility functions
β”œβ”€β”€ test
β”‚   └── test.js            Test coverage with the Node.js test runner
β”œβ”€β”€ .prettierrc            Code formatting configuration
β”œβ”€β”€ index.js               The main thread of execution
β”œβ”€β”€ README.md              you're looking at it

To set up your environment to develop this tool, run:

  • Install Node.js 20 or newer
  • npm install
  • node index

You can also run node index DEV=true CLIENT_ID=<YOUR_TESTING_CLIENT_ID> if you want to use your own client id for development and testing purposes.

The tests use the built-in Node.js test runner and can be run with npm test.

Questions? Ideas? Bugs?

If you run into any issues or you'd like to share your thoughts, feel free to open an issue in this repository or hit me up on Twitter.

Contributions

Logo designed by Rapha Lopes. Thanks to @sergiou87, @zschiller, @mamuso, @anishde12020, and @jdvr for contributing with their feedback and ideas πŸ™‡β€β™‚οΈ.

License

The tool is available as open-source under the terms of the MIT License.