Skip to content

Commit 0c04263

Browse files
authored
Merge pull request #138 from rcjackson/nightly_build
ADD: Nightly builds
2 parents 98c2df8 + aed2712 commit 0c04263

File tree

6 files changed

+131
-23
lines changed

6 files changed

+131
-23
lines changed

.github/workflows/antivirus.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
on:
2+
pull_request:
3+
types: [assigned, opened, synchronize, reopened, closed]
4+
5+
jobs:
6+
gitavscan:
7+
runs-on: ubuntu-latest
8+
name: AV scan
9+
steps:
10+
- uses: actions/checkout@v5
11+
- name: Git AV Scan
12+
uses: djdefi/gitavscan@main
13+
with:
14+
full: '--full'

.github/workflows/build-docs.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,27 +16,28 @@ jobs:
1616
run:
1717
shell: bash -l {0}
1818
steps:
19-
- uses: actions/checkout@v2
19+
- uses: actions/checkout@v5
2020

2121
# Install dependencies
2222
- name: Setup Conda Environment
23-
uses: conda-incubator/setup-miniconda@v2
23+
uses: conda-incubator/setup-miniconda@v3
2424
with:
2525
environment-file: doc/environment_docs.yml
2626
activate-environment: pydda-docs
2727
auto-activate-base: false
2828
mamba-version: '*'
2929
use-mamba: true
30-
miniforge-variant: Mambaforge
3130

3231
- name: Install PyDDA
3332
run: |
3433
pip install -e .
34+
3535
# Build the website
3636
- name: Build the site
3737
run: |
3838
cd doc
3939
make html
40+
4041
# Push the book's HTML to github-pages
4142
- name: GitHub Pages action
4243
uses: peaceiris/[email protected]

.github/workflows/codeql.yml

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# For most projects, this workflow file will not need changing; you simply need
2+
# to commit it to your repository.
3+
#
4+
# You may wish to alter this file to override the set of languages analyzed,
5+
# or to provide custom queries or build logic.
6+
#
7+
# ******** NOTE ********
8+
# We have attempted to detect the languages in your repository. Please check
9+
# the `language` matrix defined below to confirm you have the correct set of
10+
# supported CodeQL languages.
11+
#
12+
name: "CodeQL"
13+
14+
on:
15+
push:
16+
branches: [ "main" ]
17+
pull_request:
18+
# The branches below must be a subset of the branches above
19+
branches: [ "main" ]
20+
schedule:
21+
- cron: '39 13 * * 2'
22+
23+
jobs:
24+
analyze:
25+
name: Analyze
26+
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
27+
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
28+
permissions:
29+
actions: read
30+
contents: read
31+
security-events: write
32+
33+
strategy:
34+
fail-fast: false
35+
matrix:
36+
language: ['python' ]
37+
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
38+
# Use only 'java' to analyze code written in Java, Kotlin or both
39+
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
40+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
41+
42+
steps:
43+
- name: Checkout repository
44+
uses: actions/checkout@v5
45+
46+
# Initializes the CodeQL tools for scanning.
47+
- name: Initialize CodeQL
48+
uses: github/codeql-action/init@v3
49+
with:
50+
languages: ${{ matrix.language }}
51+
# If you wish to specify custom queries, you can do so here or in a config file.
52+
# By default, queries listed here will override any specified in a config file.
53+
# Prefix the list here with "+" to use these queries and those in the config file.
54+
55+
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
56+
# queries: security-extended,security-and-quality
57+
58+
59+
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java).
60+
# If this step fails, then you should remove it and run the build manually (see below)
61+
- name: Autobuild
62+
uses: github/codeql-action/autobuild@v3
63+
64+
# ℹ️ Command-line programs to run using the OS shell.
65+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
66+
67+
# If the Autobuild fails above, remove it and uncomment the following three lines.
68+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
69+
70+
# - run: |
71+
# echo "Run, Build Application using script"
72+
# ./location_of_script_within_repo/buildscript.sh
73+
74+
- name: Perform CodeQL Analysis
75+
uses: github/codeql-action/analyze@v3
76+
with:
77+
category: "/language:${{matrix.language}}"

.github/workflows/linting.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ jobs:
2323
if: ${{ needs.pre-job.outputs.should_skip != 'true' }}
2424
steps:
2525
- name: Cancel Previous Runs
26-
uses: styfle/cancel-workflow-action@0.9.1
26+
uses: styfle/cancel-workflow-action@0.12.1
2727
with:
2828
access_token: ${{ github.token }}
29-
- uses: actions/checkout@v2
30-
- uses: actions/setup-python@v2
31-
- uses: pre-commit/action@v2.0.3
29+
- uses: actions/checkout@v5
30+
- uses: actions/setup-python@v6
31+
- uses: pre-commit/action@v3.0.1

.github/workflows/python-package-conda.yml

Lines changed: 31 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ on:
55
branches: [ main ]
66
pull_request:
77
branches: [ main ]
8+
schedule:
9+
- cron: '0 2 * * *' # Runs at 2:00 AM UTC every day
810

911
jobs:
1012
build:
@@ -17,7 +19,7 @@ jobs:
1719
strategy:
1820
fail-fast: false
1921
matrix:
20-
python-version: ["3.10", "3.11", "3.12"]
22+
python-version: ["3.10", "3.11", "3.12", "3.13"]
2123
os: [macOS, ubuntu]
2224
inlcude:
2325
- os: macos-latest
@@ -26,25 +28,40 @@ jobs:
2628
platform: [x64]
2729

2830
steps:
29-
- uses: actions/checkout@v2
30-
- name: Setup Conda Environment
31-
uses: conda-incubator/setup-miniconda@v2
31+
- uses: actions/checkout@v5
32+
- name: Install Conda environment with Micromamba
33+
uses: mamba-org/setup-micromamba@v2.0.6
3234
with:
33-
python-version: ${{ matrix.python-version }}
34-
environment-file: ./continuous_integration/environment-actions.yml
35-
activate-environment: pydda_env
36-
auto-activate-base: False
37-
mamba-version: '*'
38-
use-mamba: true
39-
miniforge-variant: Mambaforge
35+
environment-file: continuous_integration/environment-actions.yml
36+
micromamba-version: '2.0.0-0'
37+
environment-name: pydda-env
38+
cache-downloads: false
39+
40+
- name: Install PyDDA
41+
shell: bash -l {0}
42+
run: |
43+
python -m pip install -e . --no-deps --force-reinstall
44+
4045
- name: Lint with flake8
46+
shell: bash -l {0}
4147
run: |
42-
conda install flake8
48+
pip install flake8
4349
# stop the build if there are Python syntax errors or undefined names
4450
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
4551
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
4652
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
53+
4754
- name: Test with pytest
55+
shell: bash -l {0}
4856
run: |
49-
conda install pytest
50-
pytest
57+
pip install pytest
58+
python -m pytest -v --cov=./ --cov-report=xml
59+
60+
- name: Upload code coverage to Codecov
61+
uses: codecov/[email protected]
62+
with:
63+
file: ./coverage.xml
64+
flags: unittests
65+
env_vars: OS,PYTHON
66+
name: codecov-umbrella
67+
fail_ci_if_error: false

doc/environment_docs.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ channels:
33
- conda-forge
44
- defaults
55
dependencies:
6-
- python>=3.10
6+
- python
77
- pip
88
- arm_pyart
99
- cython
@@ -12,7 +12,6 @@ dependencies:
1212
- pytest-mpl
1313
- pytest-cov
1414
- cartopy
15-
- pyproj=3.3
1615
- cfgrib
1716
- eccodes
1817
- sphinx

0 commit comments

Comments
 (0)