Code Monkey home page Code Monkey logo

fancy-commit's Introduction

✨ fancy-commit ✨

Ohhh so fancy. Super simple cli for writing fancy commit messages

PRs Welcome

example gif

image

🚀 Install

npm install -g fancy-commit

🦁 Alias

I chose the name fancy-commit as it was nice and wouldn't clash with any other cli tool. I recomend aliasing it to something else in your command line. For bash I add the following line to my .bashrc file 😊

alias gc='fancy-commit'

🤟 Usage

The basic functionality of this package can be run simply via fancy-commit. On its own, this command will use default values for all settings. This can be overwritten via config however!

🎩 Commands

- fancy-commit setup

This command will write a config file for you to change. It will be located in your home directory and called .fancy_commit.

- fancy-commit reset

Mess up your config file? This command will reset it to the defaults.

- fancy-commit clean

Don't need custom config? Run this command to delete your .fancy_commit file.

⚙️ Config

fancy-commit is built on config and offers a whole bunch of settings you can change to your liking.

config key description default possible values
prompts An array of commit prompts for you to use. see here Array items be in the format of { text: 'Feature', emoji: '🚀' }
skipVerifyingCommit Skip verifying your commit. Adds --no-verify to the commit to skip and pre-commit checks. ask_n always, never, ask_y, ask_n (prompt config)
allowEmptyCommit Allow commits to be empty. ask_n always, never, ask_y, ask_n (prompt config)
signCommits Sign your git commits. Most commonly used to GPG sign your commits. ask_n always, never, ask_y, ask_n (prompt config)
warnNoChanges Warn you if your trying to make a commit with no changes. true true, false
mustBeInsideWorkingTree Exit fancy-commit if youre not inside a git working tree. true true, false
useGithubEmoji Use github emoji markup in commit messages in place of Unicode emoji chracters. e.g. :dog: instead of 🐶. true true, false

⁉️ Prompt config

Prompt config has 4 possible values

  • always - Don't Ask, just always do it.
  • never - Don't Ask, but never do it.
  • ask_y - Ask every time, defaulting to 'y' (yes).
  • ask_n - Ask every time, defaulting to 'n' (no).

fancy-commit's People

Contributors

dr3 avatar

Watchers

 avatar  avatar

Forkers

e-ntro-py

fancy-commit's Issues

Feature Request: Allow custom user settings

Is your feature request related to a problem? Please describe.
The current implementation requires gpg signing which not everyone wants

Describe the solution you'd like
Add the ability for a user to configure settings for the package. Could be via a file or via a CLI option (which writes to a file)

Things that could be settings:

  • gpg signing
  • Messages and emoji
  • Selection defaults (always no verify/ never no verify)

Feature Request: Add better empty commit support

Is your feature request related to a problem? Please describe.
Don't bother the user regarding empty commits if there are changes being committed

Describe the solution you'd like
Detect staged changes and don't ask the user to allow empty commits if there are changes being committed.

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.