Skip to content

Latest commit

 

History

History
283 lines (214 loc) · 7.32 KB

README.en.md

File metadata and controls

283 lines (214 loc) · 7.32 KB

pummit 🚛

Test CLI最終コミットリポジトリのスター問題オープンな問題バグの問題

image

What is this?

You can easily create beautiful commit messages like this one.

image
  • Select Language
🎌日本語 🤡English 🐉简体中文 🍜繁体中文 🌸한국어

How to use 💨

pummit can be used in two ways

pummit <emojiprefix> '<subject>'
# or
pummit '<emojiprefix> <subject>'

# Example
pummit sparkles 'I am unko man'
# Run: git commit -m ':sparkles: I am unko man (path/to/added/file, path/to/added/file)'

pummit 'sparkles I am unko man'
# Run: git commit -m ':sparkles: I am unko man (path/to/added/file, path/to/added/file)'

Install 😊

It is distributed with Homebrew.

brew tap hidemaruowo/tap
brew update
brew install pummit

If you have Go installed, run this.

go install github.com/HidemaruOwO/pummit@latest

https://github.com/HidemaruOwO/pummit/releases

If it is not installed, download the file that matches your environment from Release and run the following command.

tar xzvf pummit**.tar.gz
sudo mv pummit /usr/local/bin

Build 🔨

git clone https://github.com/HidemaruOwO/pummit.git
cd pummit
go build main.go

Dependencies 🪡

To use pummit, please register the following command in your path

  • git

To use with lazygit 🔍

the following keybindings.config/lazygit/config.ymlPlease set it to

customCommands:
  - key: "c"
    prompts:
      - type: "input"
        title: "Commit message"
        initialValue: ""
    command: "pummit '{{index .PromptResponses 0}}'"
    context: "files"
    description: "commit changes(Custom Command)"

Sample emoji prefix 🌟

# ==================== Emojis ====================
# 🎉  :tada: 初めてのコミット(Initial Commit)
# ♻️   :recycle: マージ(Merge)
# 🔖  :bookmark: バージョンタグ(Version Tag)
# ✨  :sparkles: 新機能(New Feature)
# 🐛  :bug: バグ修正(Bagfix)
# 👀  :eyes: リファクタリング(Refactoring)
# 📚  :books: ドキュメント(Documentation)
# 🎨  :art: デザインUI/UX(Accessibility)
# 🐎  :horse: パフォーマンス(Performance)
# 🔧  :wrench: ツール(Tooling)
# 🚨  :rotating_light: テスト(Tests)
# 💩  :hankey: 非推奨追加(Deprecation)
# 🗑️  :wastebasket: 削除(Removal)
# 🚧  :construction: WIP(Work In Progress)
# ☃️  :snowman: 仕様変更

# ==================== Format ====================
# :emoji: Subject (Dir/AddedFile Dir/AddedFile)
#
# Commit body...

About the alias function 📎

for examplewastebasketを入力するのは少し大変ですが、エイリアス機能を使うとwbYou can enter it easily.

$ pummit wb モジュールの削除
# Result: :wastebasket: モジュールの削除 (path/to/added/file)

The default aliases are as follows.

 📎 There is aliases
Alias : Prefix : Emoji
----------------------
  sm : snowman : ☃️
  h : horse : 🐎
  w : wrench : 🔧
  l : rotating_light : 🚨
  p : hankey : 💩
  wb : wastebasket : 🗑️
  c : construction : 🚧
  r : recycle : ♻️
  s : sparkles : ✨
  t : tada : 🎉
  e : eyes : 👀
  b : bug : 🐛
  d : books : 📚
  a : art : 🎨

Add command

This command allows you to add an alias.

$ pummit alias add 's' 'sparkles'

In this casesJust enter the alias "Emoji prefix" in the commit message.sparkleswill be able to be substituted.

$ pummit s 新機能の追加
# Run: git commit -m ':sparkles: 新機能の追加 (path/to/added/file)'

Delete command

This command allows you to delete an alias.

$ pummit alias delete s

In this case,s=spaklesIf you run this command assuming that the alias is registeredsandsparklesSince the association of Emoji prefix will be lost, even if you run the following command, the Emoji prefix will not besonly is assigned.

$ pummit s 新機能の追加
# Run: git commmit -m ':s: 新機能の追加 (path/to/added/file)'

You can also specify multiple aliases to delete as arguments.

$ pummit alias delete s sm c h

Delete --all command

This command deletes all registered aliases.

$ pummit alias delete --all

List command

This command displays all registered aliases.

$ pummit alias list

If the aliass=sparklesandt=tadaIf it is registered, the following will be output.

📎 There is aliases
Alias : Prefix : Emoji
  s : sparkles : ✨
  t : tada : 🎉

Reset command

This command resets the alias.

$ pummit alias reset

If there are so many aliases that it becomes confusing,config.jsonIt can be used as a recovery tool in case you cause a bug by directly playing with it.

$ pummit alias list
 📎 There is aliases
Alias : Prefix : Emoji
----------------------
  hjjciiiisadsadasda : sparkles : ✨
  w : wrench : 🔧
  s : sparkles : ✨
  l : rotating_light : 🚨
  p : hankey : 💩
  wb : wastebasket : 🗑️
  c : construction : 🚧
  sm : snowman : ☃️
  hj : sparkles : ✨
  hjjjksda : sparkles : ✨
  hjjca : sparkles : ✨
  hjjciiiia : sparkles : ✨
  a : art : 🎨
  h : horse : 🐎
  r : recycle : ♻️
  t : tada : 🎉
  b : bug : 🐛
  e : eyes : 👀
  d : books : 📚

Even if there are a lot of confusing aliases like this:

$ pummit alias reset
> May I reset the aliases? :(Y/n) y
[INFO] Alias reseted

 📎 There is aliases
Alias : Prefix : Emoji
----------------------
  sm : snowman : ☃️
  h : horse : 🐎
  w : wrench : 🔧
  l : rotating_light : 🚨
  p : hankey : 💩
  wb : wastebasket : 🗑️
  c : construction : 🚧
  r : recycle : ♻️
  s : sparkles : ✨
  t : tada : 🎉
  e : eyes : 👀
  b : bug : 🐛
  d : books : 📚
  a : art : 🎨

You can restore it to this beautiful state with just one command.

Special thanks ✨