Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Core Modules
dune-common
Commits
189790d5
Commit
189790d5
authored
4 years ago
by
Samuel Burbulla
Committed by
Andreas Dedner
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Add __main__.py to define commands.
parent
c00e6b48
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!932
Merge of small MRs that make changes to the Python bindings
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
python/dune/CMakeLists.txt
+1
-0
1 addition, 0 deletions
python/dune/CMakeLists.txt
python/dune/__main__.py
+20
-0
20 additions, 0 deletions
python/dune/__main__.py
python/dune/packagemetadata.py
+1
-5
1 addition, 5 deletions
python/dune/packagemetadata.py
with
22 additions
and
5 deletions
python/dune/CMakeLists.txt
+
1
−
0
View file @
189790d5
...
...
@@ -4,6 +4,7 @@ add_subdirectory(typeregistry)
add_python_targets
(
dune
__init__
__main__
create
packagemetadata
plotting
...
...
This diff is collapsed.
Click to expand it.
python/dune/__main__.py
0 → 100644
+
20
−
0
View file @
189790d5
import
sys
,
os
from
argparse
import
Action
,
ArgumentParser
from
.packagemetadata
import
get_dune_py_dir
def
configure
():
# force a reconfiguration of dune-py by deleting tagfile
tagfile
=
os
.
path
.
join
(
get_dune_py_dir
(),
"
.noconfigure
"
)
if
os
.
path
.
exists
(
tagfile
):
os
.
remove
(
tagfile
)
if
__name__
==
'
__main__
'
:
parser
=
ArgumentParser
(
description
=
'
Execute DUNE commands
'
,
prog
=
'
dune
'
)
parser
.
add_argument
(
'
command
'
,
choices
=
[
'
configure
'
],
help
=
"
Command to be executed
"
)
args
=
parser
.
parse_args
()
if
args
.
command
==
'
configure
'
:
print
(
'
Configure dune-py module
'
)
configure
()
This diff is collapsed.
Click to expand it.
python/dune/packagemetadata.py
+
1
−
5
View file @
189790d5
...
...
@@ -371,11 +371,7 @@ def metaData(version=None, dependencyCheck=True):
class
dunepyinstall
(
build_py
):
def
run
(
self
):
build_py
.
run
(
self
)
# force a reconfiguration of dune-py by deleting tagfile
tagfile
=
os
.
path
.
join
(
get_dune_py_dir
(),
"
.noconfigure
"
)
if
os
.
path
.
exists
(
tagfile
):
os
.
remove
(
tagfile
)
configure
()
setupParams
[
'
cmdclass
'
]
=
{
'
build_py
'
:
dunepyinstall
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment