Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
d9bdf16b
Commit
d9bdf16b
authored
Jul 08, 2021
by
Philipp Arras
Browse files
Remove gitversion interface
parent
ec726ff5
Pipeline
#105228
passed with stages
in 15 minutes and 45 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
ChangeLog.md
View file @
d9bdf16b
...
...
@@ -93,6 +93,13 @@ likelihood becomes the identity matrix. This is needed for the `GeoMetricKL`
algorithm.
Remove gitversion interface
---------------------------
Since we provide proper nifty releases on PyPI now, the gitversion interface is
not supported any longer.
Changes since NIFTy 5
=====================
...
...
setup.py
View file @
d9bdf16b
...
...
@@ -18,21 +18,6 @@
from
setuptools
import
find_packages
,
setup
import
os
def
write_version
():
import
subprocess
try
:
p
=
subprocess
.
Popen
([
"git"
,
"describe"
,
"--dirty"
,
"--tags"
,
"--always"
],
stdout
=
subprocess
.
PIPE
)
res
=
p
.
communicate
()[
0
].
strip
().
decode
(
'utf-8'
)
except
FileNotFoundError
:
print
(
"Could not determine version string from git history"
)
res
=
"unknown"
with
open
(
os
.
path
.
join
(
"nifty7"
,
"git_version.py"
),
"w"
)
as
f
:
f
.
write
(
'gitversion = "{}"
\n
'
.
format
(
res
))
write_version
()
exec
(
open
(
'nifty7/version.py'
).
read
())
with
open
(
"README.md"
)
as
f
:
...
...
src/version.py
View file @
d9bdf16b
# Store the version here so:
# 1) we don't load dependencies by storing it in __init__.py
# 2) we can import it in setup.py for the same reason
# 3) we can import it into your module module
__version__
=
'7.0'
def
gitversion
():
try
:
from
.git_version
import
gitversion
except
ImportError
:
return
"unknown"
return
gitversion
Philipp Arras
@parras
mentioned in merge request
!785 (merged)
·
Sep 15, 2022
mentioned in merge request
!785 (merged)
mentioned in merge request !785
Toggle commit list
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment