Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dorie
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
31
Issues
31
List
Boards
Labels
Service Desk
Milestones
Merge Requests
9
Merge Requests
9
Operations
Operations
Incidents
Environments
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
dorie
dorie
Commits
065ca211
Commit
065ca211
authored
Oct 25, 2016
by
Dion Haefner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
adjusted usage strings
parent
33096c90
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
16 deletions
+29
-16
bin/dorie.in
bin/dorie.in
+29
-16
No files found.
bin/dorie.in
View file @
065ca211
...
...
@@ -8,7 +8,7 @@ import warnings
import
subprocess
import
multiprocessing
try
:
try
:
# Python 2.x compatibility
input
=
raw_input
except
NameError
:
pass
...
...
@@ -69,32 +69,45 @@ if __name__ == "__main__": # parse command line and call command handler
try
:
with
warnings
.
catch_warnings
(
record
=
True
)
as
warn
:
parser
=
argparse
.
ArgumentParser
(
description
=
"DORiE command line interface"
,
epilog
=
"For more information check our online documentation:
\n
"
"http://dorie-docs.bitballoon.com (password: 'richards')"
epilog
=
"For more information check our online documentation:
"
"http://dorie-docs.bitballoon.com (password: 'richards')
.
"
)
subparsers
=
parser
.
add_subparsers
(
title
=
"Commands"
,
dest
=
"command"
)
subparsers
.
required
=
True
parser_run
=
subparsers
.
add_parser
(
'run'
,
help
=
"start dorie"
)
parser_run
.
add_argument
(
'config'
,
help
=
"DORiE configuration file. Can be created with 'dorie create'."
)
parser_run
.
add_argument
(
'-p'
,
'--parallel'
,
metavar
=
'N'
,
nargs
=
'?'
,
default
=
1
,
const
=
multiprocessing
.
cpu_count
(),
type
=
int
,
required
=
False
,
help
=
"Run in parallel on N processes. If N is not specified, run on all available CPU threads."
)
parser_run
.
set_defaults
(
func
=
run
)
parser_create
=
subparsers
.
add_parser
(
'create'
,
help
=
"Copy example configuration to current folder."
)
parser_create
=
subparsers
.
add_parser
(
'create'
,
description
=
"Copy example configuration to current folder."
,
help
=
"Copy example configuration to current folder."
)
parser_create
.
add_argument
(
'-f'
,
'--force'
,
help
=
"Override existing files."
,
action
=
"store_true"
)
parser_create
.
set_defaults
(
func
=
create
)
parser_pfg
=
subparsers
.
add_parser
(
'pfg'
,
help
=
"Start parameter field generator."
)
parser_pfg
=
subparsers
.
add_parser
(
'pfg'
,
help
=
"Start parameter field generator."
,
description
=
"Start parameter field generator."
,
usage
=
"%(prog)s <config> [-h] [-p [N]]"
)
parser_pfg
.
add_argument
(
'config'
,
help
=
"Configuration file for the parameter field generator. Can be created with 'dorie create'."
)
parser_pfg
.
add_argument
(
'-p'
,
'--parallel'
,
metavar
=
'N'
,
nargs
=
'?'
,
default
=
1
,
const
=
multiprocessing
.
cpu_count
(),
type
=
int
,
required
=
False
,
help
=
"Run in parallel on N processes. If N is not specified, run on all available CPU threads."
)
help
=
"Configuration file for the parameter field generator. "
"Can be created with 'dorie create'."
)
parser_pfg
.
add_argument
(
'-p'
,
'--parallel'
,
metavar
=
'N'
,
nargs
=
'?'
,
default
=
1
,
const
=
multiprocessing
.
cpu_count
(),
type
=
int
,
required
=
False
,
help
=
"Run in parallel on N processes. "
"If N is not specified, run on all available CPU threads."
)
parser_pfg
.
set_defaults
(
func
=
pfg
)
parser_plot
=
subparsers
.
add_parser
(
'plot'
,
help
=
"Plot a preview of a VTK file created by DORiE."
)
parser_run
=
subparsers
.
add_parser
(
'run'
,
help
=
"Run DORiE."
,
description
=
"Run DORiE."
,
usage
=
"%(prog)s <config> [-h] [-p [N]]"
)
parser_run
.
add_argument
(
'config'
,
help
=
"DORiE configuration file. Can be created with 'dorie create'."
)
parser_run
.
add_argument
(
'-p'
,
'--parallel'
,
metavar
=
'N'
,
nargs
=
'?'
,
default
=
1
,
const
=
multiprocessing
.
cpu_count
(),
type
=
int
,
required
=
False
,
help
=
"Run in parallel on N processes. "
"If N is not specified, run on all available CPU threads."
)
parser_run
.
set_defaults
(
func
=
run
)
parser_plot
=
subparsers
.
add_parser
(
'plot'
,
help
=
"Plot a preview of a VTK file created by DORiE."
,
description
=
"Plot a preview of a VTK file created by DORiE."
,
usage
=
"%(prog)s <vtk> [-h] [--v [VAR [VAR ...]]]"
)
parser_plot
.
add_argument
(
'vtk'
,
help
=
"Input VTK file."
)
parser_plot
.
add_argument
(
'--var'
,
nargs
=
'*'
,
required
=
False
)
parser_plot
.
add_argument
(
'-v'
,
'--var'
,
nargs
=
'*'
,
required
=
False
,
help
=
"Plot only given variables. If not specified, all variables are plotted."
)
parser_plot
.
set_defaults
(
func
=
plot
)
args
=
parser
.
parse_args
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment