-
Notifications
You must be signed in to change notification settings - Fork 144
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
Script to update all automatically generated documentation #142
Changes from 1 commit
2670983
5d54d5a
b9d0bda
514125b
d9d288b
a287975
a42bd8c
4a07116
13c45cf
320e618
0e0564b
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 |
---|---|---|
@@ -0,0 +1,81 @@ | ||
# # | ||
# Copyright 2015-2015 Ghent University | ||
# | ||
# This file is part of EasyBuild, | ||
# originally created by the HPC team of Ghent University (http://ugent.be/hpc/en), | ||
# with support of Ghent University (http://ugent.be/hpc), | ||
# the Flemish Supercomputer Centre (VSC) (https://vscentrum.be/nl/en), | ||
# the Hercules foundation (http://www.herculesstichting.be/in_English) | ||
# and the Department of Economy, Science and Innovation (EWI) (http://www.ewi-vlaanderen.be/en). | ||
# | ||
# http://github.com/hpcugent/easybuild | ||
# | ||
# EasyBuild is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License as published by | ||
# the Free Software Foundation v2. | ||
# | ||
# EasyBuild is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with EasyBuild. If not, see <http://www.gnu.org/licenses/>. | ||
# # | ||
|
||
# This script generates all readthedocs documentation that can be automatically updated. | ||
|
||
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. add yourself as an author:
|
||
|
||
#!/bin/bash | ||
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. make this the first line |
||
|
||
set -eu | ||
framework_path=`python -c "import os; import easybuild; print os.path.dirname(os.path.abspath(easybuild.__file__))"` | ||
vs=version-specific | ||
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. rename to |
||
scripts_dir=scripts | ||
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. use upper case for constants: |
||
|
||
if [ ! -d $vs ]; then | ||
echo "version-specific dir does not exits" | ||
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. exist (typo) 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. redirect to stderr with |
||
exit 1 | ||
fi | ||
|
||
if [ ! -d $scripts_dir ]; then | ||
echo "scripts dir does not exist" | ||
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. redirect to stderr with |
||
exit 1 | ||
fi | ||
|
||
generate_api_script=$scripts_dir/generate_api.py | ||
generic_easyblocks_script=$scripts_dir/generic_easyblocks.py | ||
|
||
if [ ! -f $generate_api_script -a -f $generic_easyblocks_script ]; then | ||
exit 1 | ||
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. no error msg? |
||
fi | ||
|
||
# api docs | ||
python $generate_api_script -m $framework_path | ||
|
||
# generic easyblocks doc | ||
python $generic_easyblocks_script | ||
|
||
# help doc | ||
eb --help=rst > $vs/generated_configuration_options.rst | ||
|
||
# available easyconfig params | ||
eb -a --output-format rst > $vs/generated_ec_params.rst | ||
|
||
# available configfile constants | ||
eb --avail-cfgfile-constants --output-format rst > $vs/generated_cfgfile_constants.rst | ||
|
||
# available easyconfig constants | ||
eb --avail-easyconfig-constants --output-format rst > $vs/generated_ec_constants.rst | ||
|
||
# available easyconfig licenses | ||
eb --avail-easyconfig-licenses --output-format rst > $vs/generated_ec_licenses.rst | ||
|
||
# available easyconfig templates | ||
eb --avail-easyconfig-templates --output-format rst > $vs/generated_ec_templates.rst | ||
|
||
# list-easyblocks doc | ||
eb --list-easyblocks --output-format rst > version-specific/generated_list_easyblocks.rst | ||
|
||
# list-toolchain doc | ||
eb --list-toolchains --output-format rst > version-specific/generated_list_toolchains.rst |
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.
... updates all EasyBuild documentation that can be automatically generated