mirror of
https://github.com/lucaspalomodevelop/indico-plugins.git
synced 2026-03-12 23:27:22 +00:00
Support excluding plugins from indico-plugins pkg
currently excluded: - livesync_debug (useless/example) - search_invenio (broken) - vc_dummy (useless/example)
This commit is contained in:
parent
47acd2ed39
commit
95bcdf3e30
@ -1,2 +0,0 @@
|
||||
# depends on pyxrootd which needs to be installed manually
|
||||
indico-plugin-storage-xrootd: xrootd
|
||||
8
_meta/meta.yaml
Normal file
8
_meta/meta.yaml
Normal file
@ -0,0 +1,8 @@
|
||||
extras:
|
||||
# depends on pyxrootd which needs to be installed manually
|
||||
indico-plugin-storage-xrootd: xrootd
|
||||
|
||||
skip:
|
||||
- indico-plugin-livesync-debug
|
||||
- indico-plugin-search-invenio
|
||||
- indico-plugin-vc-dummy
|
||||
@ -26,7 +26,6 @@ plugins_require = [
|
||||
'indico-plugin-importer==1.0.dev0',
|
||||
'indico-plugin-importer-invenio==1.0.dev0',
|
||||
'indico-plugin-livesync==1.0.dev0',
|
||||
'indico-plugin-livesync-debug==1.0.dev0',
|
||||
'indico-plugin-livesync-invenio==1.0.dev0',
|
||||
'indico-plugin-payment-manual==1.0.dev0',
|
||||
'indico-plugin-payment-paypal==1.0.dev0',
|
||||
@ -34,8 +33,6 @@ plugins_require = [
|
||||
'indico-plugin-previewer-code==1.0.dev0',
|
||||
'indico-plugin-previewer-jupyter==1.0.dev0',
|
||||
'indico-plugin-search==1.0.dev0',
|
||||
'indico-plugin-search-invenio==1.0.dev0',
|
||||
'indico-plugin-vc-dummy==1.0.dev0',
|
||||
'indico-plugin-vc-vidyo==1.0.dev0',
|
||||
]
|
||||
extras_require = {
|
||||
|
||||
@ -47,16 +47,17 @@ def _find_plugins():
|
||||
yield name.group(2), version.group(2)
|
||||
|
||||
|
||||
def _get_extras():
|
||||
def _get_config():
|
||||
rv = {'extras': {}, 'skip': []}
|
||||
try:
|
||||
f = open('_meta/extras.yaml')
|
||||
f = open('_meta/meta.yaml')
|
||||
except IOError as exc:
|
||||
if exc.errno != errno.ENOENT:
|
||||
raise
|
||||
return {}
|
||||
else:
|
||||
with f:
|
||||
return yaml.safe_load(f)
|
||||
rv.update(yaml.safe_load(f))
|
||||
return rv
|
||||
|
||||
|
||||
def _update_meta(data):
|
||||
@ -78,13 +79,15 @@ def cli():
|
||||
click.secho('Could not find meta package (_meta subdir)', fg='red', bold=True)
|
||||
sys.exit(1)
|
||||
|
||||
extras = _get_extras()
|
||||
config = _get_config()
|
||||
plugins_require = []
|
||||
extras_require = defaultdict(list)
|
||||
for name, version in sorted(_find_plugins()):
|
||||
if name in config['skip']:
|
||||
continue
|
||||
pkgspec = '{}=={}'.format(name, version)
|
||||
if name in extras:
|
||||
extras_require[extras[name]].append(pkgspec)
|
||||
if name in config['extras']:
|
||||
extras_require[config['extras'][name]].append(pkgspec)
|
||||
else:
|
||||
plugins_require.append(pkgspec)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user