A simple wizard for generating GitHub Actions workflows for common tasks.
Project description
GitHub Actions Wizard
GitHub Actions Wizard is a simple tool for generating GitHub Actions workflows for common deployment tasks.
Built primarily for my needs, but you're free to use it, if you find it useful.
It goes beyond simple workflow generation by automatically setting up necessary permissions (such as creating AWS IAM Roles and Policies for S3 or Lambda deployments). The intent is to quickly generate the overall workflow boilerplate, and then customize by editing the generated file.
To use it, run the github-actions-wizard
CLI tool in your repository's folder, and answer the interactive prompts. The generated workflow file will be saved in your repository's .github/workflows
folder. You can customize the file further, as necessary.
Installation
You can install GitHub Actions Wizard via pip:
pip install github-actions-wizard
This will install the command-line tool as github-actions-wizard
.
Usage
Run the wizard from the root of your Git repository:
github-actions-wizard
You'll be guided through a series of prompts to select the deployment target, branch, and other details. The tool will then generate the appropriate workflow YAML file and, for AWS deployments, set up the required IAM roles and policies.
Features
- Easy workflow generation for deployments
- Automatic AWS permissions setup for S3 and Lambda deployments
- Supports multiple deployment targets for setting up pipelines like
build -> test -> [deploy0, deploy1, ...]
- Interactive CLI guides you through configuration
- Edit generated workflows to fine-tune for your project
Why?
While you can certainly write these workflow files yourself, this tool reduces the friction of setting up deployments each time a new GitHub repository is created. The deployment setup is more than just the workflow yaml file (for e.g. AWS targets need IAM Role and Policy creation).
I needed this for myself because I release a lot of projects. The deployment targets vary per project - some copy files to AWS S3, others publish to PyPI, some release on itch.io, others deploy to AWS Lambda, and so on. It's a waste of time to look up and configure CI/CD manually each time I release a new project.
Workflow Templates
- Python package - build and publish to PyPI
- npm package - build and publish to npm
- Static Hugo website - build and deploy to GitHub Pages
- Static S3 website - build and deploy to AWS S3
- Static Cloudflare Pages website - build and deploy to Cloudflare Pages
- AWS Lambda - build and deploy to AWS Lambda
- itch.io - build and publish to itch.io
- Pytest CI - run tests with pytest on push and pull request (test-only)
- Custom workflow
Custom Workflows
Deployment targets:
- AWS S3 (static site or zip-and-upload)
- AWS Lambda (function deployment)
- Publish to PyPI
- Publish to npm
- GitHub Pages
- Cloudflare Pages
- Publish to itch.io
- Add build artifacts to GitHub release
Build types:
- Python wheel (.whl) and tar.gz package
- Static site with Hugo
- Dummy build
Examples
1. Deploy to AWS S3
$ github-actions-wizard
Select a workflow template to start with:
1. Python package - build and publish to PyPI
2. npm package - build and publish to npm
3. Static website - build and deploy to GitHub Pages
4. Static website - build and deploy to AWS S3
5. Static website - build and deploy to Cloudflare Pages
6. AWS Lambda - deploy a Python function to AWS Lambda
7. itch.io - build and publish to itch.io
8. Pytest CI - run tests with pytest on push and pull request (test-only)
9. Custom workflow
Enter option number: 4
Select deployment trigger:
1. On branch push
2. On release creation
Enter option number: 1
Enter branch name (will react to pushes on this branch) [default=main]:
Enter GitHub repo [default=cmdr2/carbon]:
Enter AWS S3 path to deploy to (e.g., my-bucket-name/some/path (or path/to/file.zip)): me.cmdr2.org/carbon
Configuring S3 deploy permissions in IAM...
⚠️ **IMPORTANT:** Please ensure that you set the S3_DEPLOY_ROLE environment variable (in your GitHub repository) to <generated-arn>
✅ Workflow update complete. Workflow written: .github/workflows/gha_workflow.yml. Please customize it as necessary.
After this, pushes to the main
branch of this repo will automatically upload to AWS S3.
2. Deploy to AWS Lambda
$ github-actions-wizard
Select a workflow template to start with:
1. Python package - build and publish to PyPI
2. npm package - build and publish to npm
3. Static website - build and deploy to GitHub Pages
4. Static website - build and deploy to AWS S3
5. Static website - build and deploy to Cloudflare Pages
6. AWS Lambda - deploy a Python function to AWS Lambda
7. itch.io - build and publish to itch.io
8. Pytest CI - run tests with pytest on push and pull request (test-only)
9. Custom workflow
Enter option number: 6
Select deployment trigger:
1. On branch push
2. On release creation
Enter option number: 1
Enter branch name (will react to pushes on this branch) [default=main]:
Enter GitHub repo [default=cmdr2/blog-agent]:
Enter the AWS Lambda function name to deploy to (e.g., my-function): blog-agent
Configuring Lambda deploy permissions in IAM...
⚠️ **IMPORTANT:** Please ensure that you set the LAMBDA_DEPLOY_ROLE environment variable (in your GitHub repository) to <generated-arn>
✅ Workflow update complete. Workflow written: .github/workflows/gha_workflow.yml. Please customize it as necessary.
After this, pushes to the main
branch of this repo will automatically update the AWS Lambda Function.
3. Deploy to PyPI
$ github-actions-wizard
Select a workflow template to start with:
1. Python package - build and publish to PyPI
2. npm package - build and publish to npm
3. Static website - build and deploy to GitHub Pages
4. Static website - build and deploy to AWS S3
5. Static website - build and deploy to Cloudflare Pages
6. AWS Lambda - deploy a Python function to AWS Lambda
7. itch.io - build and publish to itch.io
8. Pytest CI - run tests with pytest on push and pull request (test-only)
9. Custom workflow
Enter option number: 1
Select deployment trigger:
1. On branch push
2. On release creation
Enter option number: 2
⚠️ **IMPORTANT:** Please ensure that you've added GitHub as a trusted publisher in your PyPI account: https://docs.pypi.org/trusted-publishers/
Note: You can use the workflow file name (gha_workflow.yml) while configuring the trusted publisher.
✅ Workflow update complete. Workflow written: .github/workflows/gha_workflow.yml. Please customize it as necessary.
Customization
After generation, you can edit the workflow YAML file in .github/workflows
to add project-specific steps or modify the configuration as needed.
FAQ
Please see this page for frequently asked questions.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file github_actions_wizard-1.9.2.tar.gz
.
File metadata
- Download URL: github_actions_wizard-1.9.2.tar.gz
- Upload date:
- Size: 18.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
f4c1aea3269f9fb0a1dcbe28febba36fc535796a8d0e2fb2cbc6715d277dcf18
|
|
MD5 |
2b55f3d7722aab2f061471f010524f11
|
|
BLAKE2b-256 |
03a63d83a70aa100e6a3cb10643cdd0453c9890726af014f73ecc3a06ea2ae02
|
Provenance
The following attestation bundles were made for github_actions_wizard-1.9.2.tar.gz
:
Publisher:
ci_deploy_workflow.yml
on cmdr2/github-actions-wizard
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
github_actions_wizard-1.9.2.tar.gz
-
Subject digest:
f4c1aea3269f9fb0a1dcbe28febba36fc535796a8d0e2fb2cbc6715d277dcf18
- Sigstore transparency entry: 554326294
- Sigstore integration time:
-
Permalink:
cmdr2/github-actions-wizard@52ee0c86472f586c1a24c4513f5f1d7c660fc840
-
Branch / Tag:
refs/tags/v1.9.2
- Owner: https://github.com/cmdr2
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
ci_deploy_workflow.yml@52ee0c86472f586c1a24c4513f5f1d7c660fc840
-
Trigger Event:
release
-
Statement type:
File details
Details for the file github_actions_wizard-1.9.2-py3-none-any.whl
.
File metadata
- Download URL: github_actions_wizard-1.9.2-py3-none-any.whl
- Upload date:
- Size: 21.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
7c2c3911975a8fa859418a789cb54f4c68b0504fb12ab7a967c73c552a957414
|
|
MD5 |
f65fc2c16eeb1a258ac7e3a8ac7e20f1
|
|
BLAKE2b-256 |
a06360144c8a0af1b3bb1ae481587f5e6dc66f9c3d14074d7a6a38e0047d366e
|
Provenance
The following attestation bundles were made for github_actions_wizard-1.9.2-py3-none-any.whl
:
Publisher:
ci_deploy_workflow.yml
on cmdr2/github-actions-wizard
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1
-
Predicate type:
https://docs.pypi.org/attestations/publish/v1
-
Subject name:
github_actions_wizard-1.9.2-py3-none-any.whl
-
Subject digest:
7c2c3911975a8fa859418a789cb54f4c68b0504fb12ab7a967c73c552a957414
- Sigstore transparency entry: 554326306
- Sigstore integration time:
-
Permalink:
cmdr2/github-actions-wizard@52ee0c86472f586c1a24c4513f5f1d7c660fc840
-
Branch / Tag:
refs/tags/v1.9.2
- Owner: https://github.com/cmdr2
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com
-
Runner Environment:
github-hosted
-
Publication workflow:
ci_deploy_workflow.yml@52ee0c86472f586c1a24c4513f5f1d7c660fc840
-
Trigger Event:
release
-
Statement type: