Command-line arguments is part of Short Circuit's Console Program Basics selection.
Scripted main
See also Program name.

For parsing command line arguments intelligently, see Parsing command-line arguments.

Example command line:

myprogram -c "alpha beta" -h "gamma"

class
    APPLICATION
inherit
    ARGUMENTS
create
    make
feature {NONE} -- Initialization
    make
            -- Print values for arguments with options 'c' and 'h'.
        do
            print ("Command line argument value for option 'c' is: ")
            print (separate_character_option_value ('c') + "%N")
            print ("Command line argument value for option 'h' is: ")
            print (separate_character_option_value ('h') + "%N")
            io.read_line    -- Keep console window open
        end
end