Skip to content
This repository has been archived by the owner on Mar 3, 2022. It is now read-only.

Creating a new command

Alex Chesters edited this page Oct 16, 2015 · 3 revisions

Follow the instructions below to create a new command

  1. Create a new file in the commands directory named my-command.rb
  2. Do your work in my-command.rb. This file should be in a similar format to below (it must contain an execute function):
    module GHI
      module Commands
        class My Command < Command
    
          def execute
            puts "Hello, world!"
          end
    
        end
      end
    end  
  3. Add your new file to the build manifest in the Rakefile
  4. Add your new command to commands.rb
  5. Add your new command to ghi help
Clone this wiki locally