diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index bcc003d..0000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,339 +0,0 @@ -version: 2.1 - -orbs: - win: circleci/windows@2.2.0 - -commands: - - bootstrap-macos: - parameters: - python-version: - type: string - steps: - - run: - name: Setup MacOS environment - command: | - curl -O https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh --silent - bash Miniconda3-latest-MacOSX-x86_64.sh -b -f >> build.log - ~/miniconda3/bin/conda create -y -n py<< parameters.python-version >> python=<< parameters.python-version >> - ln -s ~/miniconda3/envs/py<< parameters.python-version >>/bin/python ~/python3 - ~/python3 -m venv py_venv - - bootstrap-win: - parameters: - python-version: - type: string - steps: - - run: - name: Setup Win environment - command: | - conda init powershell - conda create -y -n py-<< parameters.python-version >> python=<< parameters.python-version >> - conda activate py-<< parameters.python-version >> - - bootstrap-linux: - steps: - - run: - name: Setup Linux environment - command: | - sudo apt-get update - sudo apt-get install -y build-essential - sudo apt-get install -y libblas3 \ - liblapack3 \ - liblapack-dev \ - libblas-dev - sudo apt-get install -y gfortran - - python-win-test: - parameters: - python-version: - type: string - steps: - - run: - name: Install Python dependencies - command: | - $env:CMAKE_GENERATOR = "Visual Studio 16 2019" - conda activate py-<< parameters.python-version >> - python -m pip install cmake scikit-build pybind11 - python -m pip install -r requirements-dev.txt - python -m pip install -r requirements.txt - python setup.py build_ext --inplace - - - run: - name: Test python - command: | - conda activate py-<< parameters.python-version >> - python setup.py test --verbose - - - install-python-deps: - steps: - - run: - name: Install Python dependencies - command: | - if [ `uname -s` == "Darwin" ]; then - . py_venv/bin/activate - fi - python3 --version - python3 -m pip install cmake flake8 bandit setuptools-scm - python3 -m pip install -r requirements.txt - python3 -m pip install -r requirements-dev.txt - python3 -m pip install coverage codacy-coverage - - python-build-test: - steps: - - run: - name: Build & test python - command: | - if [ `uname -s` == "Darwin" ]; then - . py_venv/bin/activate - fi - python3 setup.py build_ext --inplace - python3 setup.py test --verbose - - flake8-req-check: - steps: - - run: - name: Check code errors (pyflakes) - command: | - flake8 --select=F --per-file-ignores="__init__.py:F401" . - - flake8-opt-check: - steps: - - run: - name: Check formatting rules (PEP8) - command: | - git diff origin/master | flake8 --diff --per-file-ignores="__init__.py:F401" --exclude="setup.py" - - bandit-check: - steps: - - run: - name: Bandit security check - command: | - bandit -c bandit.yml -r camille - - codacy-check: - steps: - - run: - name: Codacy code coverage check - command: | - if [ ! -z "${CODACY_PROJECT_TOKEN}" ]; then - coverage run setup.py test; - coverage xml; - python-codacy-coverage -r coverage.xml; - fi - - create-sdist: - steps: - - run: - name: Create source package - command: | - python3 setup.py sdist - - create-wheel: - steps: - - run: - name: Create wheel - command: | - python3 -m pip install cibuildwheel==1.6.0 - python3 -m cibuildwheel --output-dir dist - - upload-pypi: - steps: - - run: - name: Upload to pypi - command: | - python3 -m pip install twine - python3 -m twine upload -u __token__ --skip-existing dist/* - -jobs: - - repo-health-check: - docker: - - image: "circleci/python:3.8" - steps: - - checkout - - bootstrap-linux - - install-python-deps - - python-build-test - - flake8-req-check - - bandit-check - - codacy-check - - python-check: - parameters: - version: - type: string - docker: - - image: "circleci/python:<< parameters.version >>" - steps: - - checkout - - bootstrap-linux - - install-python-deps - - flake8-req-check - - bandit-check - - python-build-test - - codacy-check - - python-formatting-check: - docker: - - image: "circleci/python:3.8" - steps: - - checkout - - bootstrap-linux - - install-python-deps - - flake8-opt-check - - python-macos-check: - parameters: - python-version: - type: string - macos: - xcode: 11.0.0 - steps: - - checkout - - bootstrap-macos: - python-version: << parameters.python-version >> - - install-python-deps - - python-build-test - - python-win-check: - parameters: - python-version: - type: string - executor: - name: win/default - shell: powershell.exe - steps: - - checkout - - bootstrap-win: - python-version: << parameters.python-version >> - - python-win-test: - python-version: << parameters.python-version >> - - sdist-deploy: - docker: - - image: "circleci/python:3.8" - steps: - - checkout - - bootstrap-linux - - install-python-deps - - create-sdist - - upload-pypi - - wheels-manylinux-deploy: - docker: - - image: "circleci/python:3.8" - environment: - - CIBW_BUILD: "cp38-manylinux_x86_64 cp39-manylinux_x86_64 cp310-manylinux_x86_64" - - CIBW_BEFORE_BUILD: "pip install cmake setuptools-scm -r requirements.txt && pip install -r requirements-dev.txt" - steps: - - checkout - - bootstrap-linux - - setup_remote_docker - - create-wheel - - upload-pypi - - wheels-macos-deploy: - macos: - xcode: 11.0.0 - environment: - - CIBW_BUILD: "cp38-macosx_x86_64 cp39-macosx_x86_64 cp310-macosx_x86_64" - - CIBW_BEFORE_BUILD: "pip3 install cmake setuptools-scm -r requirements.txt && pip3 install -r requirements-dev.txt" - steps: - - checkout - - create-wheel - - upload-pypi - -workflows: - version: 2 - - linux-check: - jobs: - - python-check: - name: Python 3.7 - version: "3.7" - - python-check: - name: Python 3.8 - version: "3.8" - - python-check: - name: Python 3.9 - version: "3.9" - # - python-check: - # name: Python 3.10 - # version: "3.10" - - macos-check: - jobs: - - python-macos-check: - name: MacOS Python 3.7 - python-version: "3.7" - - python-macos-check: - name: MacOS Python 3.8 - python-version: "3.8" - - python-macos-check: - name: MacOS Python 3.9 - python-version: "3.9" - # - python-macos-check: - # name: MacOS Python 3.10 - # python-version: "3.10" - - windows-check: - jobs: - - python-win-check: - name: Win Python 3.7 - python-version: "3.7" - - python-win-check: - name: Win Python 3.8 - python-version: "3.8" - - python-win-check: - name: Win Python 3.9 - python-version: "3.9" - # - python-win-check: - # name: Win Python 3.10 - # python-version: "3.10" - - linux-deploy: - jobs: - - sdist-deploy: - name: Create and deploy sdist - filters: - tags: - only: /[0-9]+(\.[0-9]+)*/ - branches: - ignore: /.*/ - - wheels-manylinux-deploy: - name: Create and deploy linux wheels - requires: - - Create and deploy sdist - filters: - tags: - only: /[0-9]+(\.[0-9]+)*/ - branches: - ignore: /.*/ - - macos-deploy: - jobs: - - wheels-macos-deploy: - name: Create and deploy macos wheels - filters: - tags: - only: /[0-9]+(\.[0-9]+)*/ - branches: - ignore: /.*/ - - optional: - jobs: - - python-formatting-check: - name: Python formatting check - - health-check: - triggers: - - schedule: - cron: "0 0 * * *" - filters: - branches: - only: - - master - jobs: - - repo-health-check