Skip to content
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

Make cylc a module #2990

Merged
merged 32 commits into from
Apr 25, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
2c4cdfa
Delete jinja2 folder
Mar 11, 2019
3a6a814
Delete markupsafe folder
Mar 11, 2019
91293d3
Delete isodatetime folder
Mar 11, 2019
ac4a5f9
Fix typo in comment
Mar 11, 2019
338ae3d
Update .gitignore with entries for setuptools
Mar 12, 2019
782eab9
Add setup.cfg
Mar 12, 2019
3da3033
Add setup.py
Mar 12, 2019
29ddac0
Update travis ci to use setup.py
Mar 12, 2019
23d7c98
Update setup.cfg RPM dependencies to match Python 3
Mar 12, 2019
6880710
Move static metadata to setup.cfg
Mar 12, 2019
d6fc347
Remove mock from dependencies as this is now part of unittest post py3
kinow Mar 12, 2019
9db0c21
Fix python requirement (was 3.5, is 3.6)
kinow Mar 12, 2019
43066a3
Remove Development Status lines from project metadata classifiers
Mar 12, 2019
a113d33
Remove tox dependencies
Mar 12, 2019
13aaa0e
Add Python 3.7 to metadata classifiers
Mar 12, 2019
40848b0
Use new way of finding Cylc's version
kinow Mar 20, 2019
b805815
Remove licences from old bundled dependencies
kinow Mar 21, 2019
28a312d
Add testfixture test dependency (after bandit fixes)
kinow Mar 21, 2019
e5ba19b
Add [docs] dependency group for sphinx and other documentation-specif…
kinow Mar 21, 2019
0b29645
Run pip install just once for all Travis tasks
Mar 25, 2019
d41dbe1
Check for Travis build dir in test-battery
Mar 27, 2019
466f5f3
Simplify cylc version, and remove another usage of CYLC_DIR
kinow Apr 5, 2019
d3a9db1
Remove ignore settings for output of cylc-make-docs in docs folder
kinow Apr 5, 2019
a4f8e10
Remove cylc-make-docs
kinow Apr 5, 2019
9d36f30
Add Sphinx command to setuptools
kinow Apr 5, 2019
d0f668e
Use sphinx via setup.py in docs stage
kinow Apr 5, 2019
0edfba5
Python 3.7 and freeze setup_requires dependency
kinow Apr 6, 2019
74558c4
Freeze dependencies
kinow Apr 6, 2019
226b54f
Fix shellcheck errors
Apr 7, 2019
b4b05f4
Lock on patch version for setup.py requirements
Apr 8, 2019
59afd76
Ignore mypy folder
kinow Apr 13, 2019
c038e84
Make sure we use Jinja2 >= 2.10.1, and less than 2.11.0
kinow Apr 13, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 14 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,8 @@
*.py[cod]
__pycache__/

# Generated documentation files (from 'cylc make-docs')
# - Command reference from called script 'custom/make-commands.sh'.
doc/src/appendices/command-ref.rst
# - Main directories of generated sphinx docs (guides) files.
doc/built-sphinx/
doc/built-sphinx-single/
# - Installed docs
doc/install/

# vim backup files
*.swp
Expand Down Expand Up @@ -40,3 +34,17 @@ passphrase
.coverage.*
coverage.xml
htmlcov/

# distutils files
build
dist
MANIFEST
cylc.egg-info
.eggs

# virtualenv
venv

# mypy
.mypy_cache/

2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,4 @@ jobs:
install:
- .travis/install.sh docs
script:
- cylc make-docs
- python setup.py build_sphinx
8 changes: 2 additions & 6 deletions .travis/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,24 +26,20 @@ args=("$@")

if grep -E '(unit-tests|functional-tests)' <<< "${args[@]}"; then
sudo apt-get install heirloom-mailx
# coverage dependencies
pip install coverage pytest-cov
# common Cylc reqirements
pip install colorama python-jose zmq empy
fi

if grep 'unit-tests' <<< "${args[@]}"; then
sudo apt-get install shellcheck
pip install pycodestyle pytest testfixtures empy
fi

# install dependencies required for building documentation
if grep 'docs' <<< "${args[@]}"; then
pip install sphinx
# for PDF output via LaTeX builder
sudo apt-get install texlive-latex-base
fi

pip install -e ."[all]"

# configure local SSH for Cylc jobs
ssh-keygen -t rsa -f ~/.ssh/id_rsa -N "" -q
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys
Expand Down
23 changes: 0 additions & 23 deletions Makefile

This file was deleted.

21 changes: 2 additions & 19 deletions bin/cylc
Original file line number Diff line number Diff line change
Expand Up @@ -21,32 +21,15 @@ CATEGORIES=('control' 'con' 'information' 'info' 'all' 'task' 'license' \

HELP_OPTS=('help' '--help' '-h' 'h' '?')

get_version() {
CYLC_VERSION="$(python -c "from cylc import __version__;\
print(__version__)")"
}

print_version() {
get_version
if [[ "$#" -eq 0 ]]; then
echo "$CYLC_VERSION"
fi
if [[ "$*" == 'long' || "$*" == '--long' ]]; then
echo "Cylc ${CYLC_VERSION} (${CYLC_DIR})"
fi
python3 -c "from cylc import __version__; print(__version__)"
}

init_cylc() {
set -eu

CYLC_HOME_BIN=$(cd "$(dirname "$0")" && pwd -P)
CYLC_DIR="$(dirname "${CYLC_HOME_BIN}")"

PATH="$(path_lead "${PATH:-}" "${CYLC_HOME_BIN}")"
PYTHONPATH="$(path_lead "${PYTHONPATH:-}" "${CYLC_DIR}/lib/")"
PYTHONUNBUFFERED='true'

export PATH PYTHONPATH PYTHONUNBUFFERED CYLC_DIR
export PYTHONUNBUFFERED
}

help_util() {
Expand Down
3 changes: 1 addition & 2 deletions bin/cylc-documentation
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ def main():

parser.add_option(
"--local",
help=("Open the local documentation (if it has been built, see cylc "
"make-docs)."),
help="Open the local documentation (if it has been built).",
action="store_true", default=False, dest="local")

parser.add_option(
Expand Down
2 changes: 0 additions & 2 deletions bin/cylc-help
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,6 @@ admin_commands = {}
admin_commands['test-battery'] = ['test-battery']
admin_commands['import-examples'] = ['import-examples']
admin_commands['check-software'] = ['check-software']
admin_commands['make-docs'] = ['make-docs']

preparation_commands = {}
preparation_commands['register'] = ['register']
Expand Down Expand Up @@ -332,7 +331,6 @@ comsum = {}
comsum['test-battery'] = 'Run a battery of self-diagnosing test suites'
comsum['import-examples'] = 'Import example suites your suite run directory'
comsum['check-software'] = 'Check required software is installed'
comsum['make-docs'] = 'Build the HTML documentation with Sphinx.'
# preparation
comsum['register'] = 'Register a suite for use'
comsum['print'] = 'Print registered suites'
Expand Down
51 changes: 0 additions & 51 deletions bin/cylc-make-docs

This file was deleted.

5 changes: 5 additions & 0 deletions bin/cylc-test-battery
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@ export CYLC_TEST_IS_GENERIC=true
CYLC_TEST_TIME_INIT="$(date -u +'%Y%m%dT%H%M%SZ')"
export CYLC_TEST_TIME_INIT

# CYLC_DIR does not work under virtualenv
if [[ -n ${TRAVIS_BUILD_DIR:-} ]]; then
export CYLC_DIR="${TRAVIS_BUILD_DIR}"
fi

if [[ "$PWD" != "$CYLC_DIR" ]]; then
echo "cd \"$CYLC_DIR\""
cd "$CYLC_DIR" || exit 1
Expand Down
20 changes: 0 additions & 20 deletions lib/isodatetime/__init__.py

This file was deleted.

Loading