DEV Community

Cover image for Scaffold your GitHub actions with Yeoman generator 🚀
Rocktim Saikia
Rocktim Saikia

Posted on

Scaffold your GitHub actions with Yeoman generator 🚀

I created a Yeoman generator to easily scaffold your javascript-based Github actions.

GitHub logo RocktimSaikia / generator-github-action

Yeoman generator for scaffolding your javascript github action.

generator-github-action

A yeoman generator for scaffolding your javascript Github action

npm

💡 About

This is a yeoman generator for the official github action template for javascript provided by the Github team.

âš¡ Installation

skip the first step if you already have yeoman installed globally.

npm install -g yo
npm install -g generator-github-action
Enter fullscreen mode Exit fullscreen mode

Then generate your new project:

yo github-action
Enter fullscreen mode Exit fullscreen mode

License

Apache-2.0 © Rocktim Saikia

Since the #actionshackathon is going on, there are going to be lots of forking and templating boilerplates. So I sat down and decided to create a Generator for this specific task so that you don't have to fork boilerplates every time you want to create a new Github Action.

Here is the Installation process followed by the Usage steps:

Installation

npm install -g yo
npm install -g generator-github-action
Enter fullscreen mode Exit fullscreen mode

If you already have yo installed globally then skip the first step. Install the generator only.

Example usage

yo github-action
Enter fullscreen mode Exit fullscreen mode

Alt Text

That will present a prompt asking a few questions about your project name and description etc. After that, It will generate a minimal set up for you to work on a javascript based Github action.

The generator will also install the bare minimum dependencies too so you don't have to worry about installion. You can just focus on writing your code for the action.

That's all 🦄 🦄 🦄

If you want to contribute to the project you can do that too. You can also leave star âš¡ if you find this tool helpful that helps on keeping me motivated to keep creating these types of tools and modules.

Top comments (0)