GithubHelp home page GithubHelp logo

alfred-conventional-commits's Introduction

alfred-conventional-commits

Build Git commit messages according to the Conventional Commits format

Install

  • You need to have Alfred installed with the Powerpack enbled.

Download the workflow from the Release Page and double-click.

What is this?

Conventional Commits is a way to write Git messages in a standard format that makes it easier to read for humans and computers.

We use the Angular flavor of Conventional Commits.

How do I use it?

  1. Start the workflow.
    • Invoke Alfred and type conv. See Settings for other ways to run the workflow.
  2. You’ll be guided step-by-step to write your commit message.
  3. The final message will be on the clipboard. Paste it into your Git application and commit.

What does the final commit message look like?

The workflow will build the commit message for you. It will have the following parts:

Each message begins with a type. We support the Angular types: build, ci, docs, feat, fix, perf, refactor, style, and test.

Then there’s a scope in parentheses that identifies the component or part of your code that was modified. This is optional.

Then there may be an ! exclamation point, which indicates that this is a breaking change. If you are using semantic-release this can trigger a major version number bump.

Then there’s a : colon, followed by your commit message.

Any commit message can be prefixed with a standard emoji. This is optional. If you never want emoji, they can be turned off using the Settings.

Some examples of commit messages are:

  • refactor!: update to use a new version of Node
    • A breaking change
  • refactor(widget)!: ♻️ update to use a new version of Node
    • A breaking change to the widget component (with optional emoji)
  • feat: ✨ add support for unicorns
    • Add a new feature (with optional emoji)
  • fix: reticulate splines correctly
    • Fix a bug

Settings

To customize the workflow, open Alfred’s preferences and select Workflows. Then select the Conventional Commits workflow. Here are the things you can customize:

Click the [x] in the upper-right corner of Alfred to set the following:

  • useEmoji can be set to ask, always, or never.
    • ask will ask each time if you want an emoji
    • always will always add an emoji
    • never will never add an emoji
  • useScope can be set to yes or no.
    • yes will show the scope prompt. You can leave it blank if you don’t want a scope for this particular commit message.
    • no will skip the scope prompt. This is useful if your organization never uses the scope feature.

Double-click the following boxes to configure them:

  • Keyword: The default Alfred keyword to trigger the workflow is conv.
  • Hotkey: Use this to set a hotkey that triggers the workflow.
  • Snippet: Use this to configure a snippet trigger. For example, if you set the snippet keyword to conv and the trigger to \\, then the workflow will be triggered when you type \\conv in any text field in any application, such as within the message field of your Git application.

alfred-conventional-commits's People

Contributors

natesilva avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.