module CommandKit::ProgramName::ClassMethods
Class-level methods.
Constants
- IGNORED_PROGRAM_NAMES
List of `$PROGRAM_NAME`s that should be ignored.
Public Instance Methods
program_name()
click to toggle source
The current program name (`$PROGRAM_NAME`).
@return [String, nil]
The `$PROGRAM_NAME` or `nil` if the `$PROGRAM_NAME` is `-e`, `irb`, or `rspec`.
@api semipublic
# File lib/command_kit/program_name.rb, line 50 def program_name $PROGRAM_NAME unless IGNORED_PROGRAM_NAMES.include?($PROGRAM_NAME) end