diff --git a/autogitc.gemspec b/autogitc.gemspec index dfea818..39a46dc 100644 --- a/autogitc.gemspec +++ b/autogitc.gemspec @@ -2,7 +2,7 @@ Gem::Specification.new do |s| s.name = 'autogitc' - s.version = '0.3.2' + s.version = '0.3.3' s.summary = 'Auto-generate Git commit messages with LLM' s.description = 'This gem simplifies the commit process by automatically generating descriptive commit messages based on the files that have been added to the Git staging area. It leverages LLM to analyze the changes and create meaningful commit messages, helping you maintain a clean and organized commit history.' s.authors = ['Adrian Goh'] diff --git a/bin/autogitc b/bin/autogitc index 0374b97..073c803 100755 --- a/bin/autogitc +++ b/bin/autogitc @@ -3,6 +3,21 @@ require 'bundler/setup' require_relative '../lib/commit_generator' require_relative '../lib/pr_template_generator' +if ARGV.include?('--help') + puts <<~HELP + Usage: autogitc [options] + + Options: + pr Generate a pull request template + --base= Specify the base branch (default: main) + --nocommit, --nc Run without committing changes + --text= Specify text that must be included in the commit + --help Display this help message + --version Show the version of autogitc + HELP + exit +end + if ARGV.include?('--version') gemspec = Gem::Specification.load('autogitc.gemspec') puts "autogitc version #{gemspec.version}"