Skip to content

Commit 07d36eb

Browse files
committed
better help per @LKedward
1 parent d2c63b3 commit 07d36eb

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

fpm/src/fpm_command_line.f90

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -248,11 +248,11 @@ subroutine get_command_line_settings(cmd_settings)
248248
elseif(len_trim(cmdarg).eq.0)then
249249
write(stdout,'(*(a))')'Fortran Package Manager:'
250250
write(stdout,'(*(a))')' '
251-
write(stdout,'(*(a))')' subcommand may be one of'
252251
call printhelp(help_list_nodash)
253252
else
254253
write(stderr,'(*(a))')'ERROR: unknown subcommand [', &
255254
& trim(cmdarg), ']'
255+
call printhelp(help_list_dash)
256256
endif
257257
call printhelp(help_text)
258258

@@ -286,14 +286,21 @@ function is_fortran_name(line) result (lout)
286286
end function is_fortran_name
287287

288288
subroutine set_help()
289-
help_list_nodash=[character(len=80) :: &
290-
' ', &
291-
' build Compile the package placing results in the "build" directory', &
292-
' help Display help ', &
293-
' list Display this list of subcommand descriptions ', &
294-
' new Create a new Fortran package directory with sample files ', &
295-
' run Run the local package application programs ', &
296-
' test Run the test programs ', &
289+
help_list_nodash=[character(len=80) :: &
290+
'USAGE: fpm [ SUBCOMMAND [SUBCOMMAND_OPTIONS] ] | [--help|--version] ', &
291+
' where SUBCOMMAND is commonly new|build|run|test ', &
292+
' ', &
293+
' subcommand may be one of ', &
294+
' ', &
295+
' build Compile the package placing results in the "build" directory', &
296+
' help Display help ', &
297+
' list Display this list of subcommand descriptions ', &
298+
' new Create a new Fortran package directory with sample files ', &
299+
' run Run the local package application programs ', &
300+
' test Run the test programs ', &
301+
' ', &
302+
' Enter "fpm --list" for a brief list of subcommand options. Enter ', &
303+
' "fpm --help" or "fpm SUBCOMMAND --help" for detailed descriptions. ', &
297304
' ']
298305
help_list_dash = [character(len=80) :: &
299306
' ', &
@@ -305,13 +312,6 @@ subroutine set_help()
305312
' test [NAME(s)] [--release] [--list] [-- ARGS] ', &
306313
' ']
307314
help_usage=[character(len=80) :: &
308-
' ', &
309-
'USAGE: fpm [ SUBCOMMAND [SUBCOMMAND_OPTIONS] ] | [--help|--version] ', &
310-
' where SUBCOMMAND is commonly new|build|run|test ', &
311-
' ', &
312-
' Enter "fpm list " or "fpm --list" for a full list of ', &
313-
' subcommands. Enter "fpm --help" or "fpm SUBCOMMAND --help" ', &
314-
' for detailed command information. ', &
315315
'' ]
316316
help_fpm=[character(len=80) :: &
317317
'NAME ', &
@@ -386,7 +386,7 @@ subroutine set_help()
386386
'SYNOPSIS ', &
387387
' fpm list [-list] ', &
388388
' ', &
389-
' fpm run --help|--version ', &
389+
' fpm list --help|--version ', &
390390
' ', &
391391
'DESCRIPTION ', &
392392
' Display a short description for each fpm(1) subcommand. ', &

0 commit comments

Comments
 (0)