Some time ago, I wrote an article about preventing deploys on Friday as part of CI/CD. I provided an example for GitLab CI/CD. GitHub Actions became popular, and I decided to publish an open-source action you can integrate into your workflows.
Go to your workflow YAML file, and add the following few lines to your job steps:
- uses: HormCodes/do-not-deploy-on-friday@v1 with: timezone: Europe/Oslo
The action will fail in case the workflow execution is on Friday. Check the README for more details about possible inputs and outputs.
- Use @vercel/ncc to compile your sources (and used
node_modules) into a single file. It also has built-in TypeScript support.
- Official documentation for GitHub Actions recommends including a build directory in the
mainbranch. Create an independent commission with a tag that contains just the build.
- GitHub action should follow semantic versioning, but users should use the major version tag
- It is not easy to create CI/CD for publishing actions to the marketplace. I ended up combining semantic-release and JasonEtco/build-and-tag-action. You can check my pipeline here.
The repository is open source, and external contributions are welcome. Please share with me your feedback or projects that are using this action.