-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add yapremisrw2, yet another PREMIS reader/writer plugin #34
base: master
Are you sure you want to change the base?
Changes from 1 commit
ea868f3
ee177cf
804a295
afa67e2
13d78b1
55a394e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,18 +11,30 @@ | |
from codecs import open | ||
from os import path | ||
|
||
from metsrw import __version__ | ||
|
||
here = path.abspath(path.dirname(__file__)) | ||
|
||
# Get the long description from the relevant file | ||
with open(path.join(here, 'README.md'), encoding='utf-8') as f: | ||
with open(path.join(HERE, 'README.md'), encoding='utf-8') as f: | ||
long_description = f.read() | ||
|
||
|
||
def get_version(): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was also done in archivematica-fpr-admin. It looks a bit different - which method you prefer? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, I think raising a |
||
version = '0.1.0' | ||
with open(path.join(HERE, 'metsrw', '__init__.py')) as fi: | ||
for line in fi: | ||
if line.startswith('__version__'): | ||
parts = line.strip().split() | ||
try: | ||
version = parts[2].replace("'", '').replace('"', '').strip() | ||
except (IndexError, AttributeError): | ||
continue | ||
return version | ||
|
||
|
||
setup( | ||
name='metsrw', | ||
version=__version__, | ||
version=get_version(), | ||
|
||
description='Library for dealing with METS files.', | ||
long_description=long_description, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You haven't renamed the global yet right? Is still reads
here
.