diff --git a/medcat-v1/.github/workflows/codeql.yml b/.github/workflows/codeql.yml similarity index 88% rename from medcat-v1/.github/workflows/codeql.yml rename to .github/workflows/codeql.yml index dce6b8984..2da4e6849 100644 --- a/medcat-v1/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -9,7 +9,7 @@ # the `language` matrix defined below to confirm you have the correct set of # supported CodeQL languages. # -name: "CodeQL" +name: "CodeQL Advanced" on: push: @@ -17,7 +17,7 @@ on: pull_request: branches: [ "main" ] schedule: - - cron: '36 14 * * 0' + - cron: '19 7 * * 0' jobs: analyze: @@ -28,7 +28,6 @@ jobs: # - https://gh.io/using-larger-runners (GitHub.com only) # Consider using larger runners or machines with greater resources for possible analysis time improvements. runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }} - timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }} permissions: # required for all workflows security-events: write @@ -44,11 +43,13 @@ jobs: fail-fast: false matrix: include: + - language: actions + build-mode: none - language: javascript-typescript build-mode: none - language: python build-mode: none - # CodeQL supports the following values keywords for 'language': 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift' + # CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'rust', 'swift' # Use `c-cpp` to analyze code written in C, C++ or both # Use 'java-kotlin' to analyze code written in Java, Kotlin or both # Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both @@ -60,6 +61,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 + # Add any setup steps before running the `github/codeql-action/init` action. + # This includes steps like installing compilers or runtimes (`actions/setup-node` + # or others). This is typically only required for manual builds. + # - name: Setup runtime (example) + # uses: actions/setup-example@v1 + # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL uses: github/codeql-action/init@v3 diff --git a/medcat-v1-tutorials/.github/workflows/main.yml b/.github/workflows/medcat-v1-tutorials_main.yml similarity index 82% rename from medcat-v1-tutorials/.github/workflows/main.yml rename to .github/workflows/medcat-v1-tutorials_main.yml index ed7b70d58..d3c778785 100644 --- a/medcat-v1-tutorials/.github/workflows/main.yml +++ b/.github/workflows/medcat-v1-tutorials_main.yml @@ -1,10 +1,17 @@ -name: build +name: medcat-v1-tutorials - Test on: push: branches: [ main ] pull_request: - branches: [ main ] + paths: + - 'medcat-v1/**' + - 'medcat-v1-tutorials/**' + - '.github/workflows/medcat-v1**' + - '.github/workflows/medcat-v1-tutorials**' +defaults: + run: + working-directory: ./medcat-v1-tutorials jobs: main: diff --git a/medcat-v1/.github/workflows/main.yml b/.github/workflows/medcat-v1_main.yml similarity index 92% rename from medcat-v1/.github/workflows/main.yml rename to .github/workflows/medcat-v1_main.yml index 5ecc1e254..b4d7ddb8c 100644 --- a/medcat-v1/.github/workflows/main.yml +++ b/.github/workflows/medcat-v1_main.yml @@ -1,11 +1,15 @@ -name: build +name: medcat-v1 - build on: push: branches: [ main ] pull_request: - branches: [ main ] - + paths: + - 'medcat-v1/**' + - '.github/workflows/medcat-v1**' +defaults: + run: + working-directory: ./medcat-v1 jobs: build: @@ -70,12 +74,13 @@ jobs: python tests/check_deprecations.py "$VERSION" --next-version --remove-prefix publish-to-test-pypi: - + # Disable pypy publish waiting for TEST_PYPI_API_TOKEN if: | - github.repository == 'CogStack/MedCAT' && + github.repository == 'CogStack/cogstack-nlp' && github.ref == 'refs/heads/main' && github.event_name == 'push' && - startsWith(github.ref, 'refs/tags') != true + startsWith(github.ref, 'refs/tags') != true && + false runs-on: ubuntu-24.04 timeout-minutes: 45 concurrency: publish-to-test-pypi diff --git a/medcat-v1/.github/workflows/production.yml b/.github/workflows/medcat-v1_production.yml similarity index 79% rename from medcat-v1/.github/workflows/production.yml rename to .github/workflows/medcat-v1_production.yml index 0db12f53c..89b037ca4 100644 --- a/medcat-v1/.github/workflows/production.yml +++ b/.github/workflows/medcat-v1_production.yml @@ -1,16 +1,25 @@ -name: production +# TODO: Fix Medcat V1 Release Actions +# Disabled waiting for designed release process +# Disabled waiting for PYPI_API_TOKEN +name: medcat-v1 - production on: push: - branches: [ production, "v[0-9]+.[0-9]+.post" ] - release: - types: [ published , edited ] - + branches: [ "medcat-v1/production", "medcat-v1/v[0-9]+.[0-9]+.post" ] + + # release: + # types: [ published , edited ] +defaults: + run: + working-directory: ./medcat-v1 jobs: build-n-publish-to-pypi: + runs-on: ubuntu-24.04 concurrency: build-n-publish-to-pypi - if: github.repository == 'CogStack/MedCAT' + if: | + github.repository == 'CogStack/cogstack-nlp' && + false steps: - name: Checkout production diff --git a/medcat-v1-tutorials/.github/.DS_Store b/medcat-v1-tutorials/.github/.DS_Store deleted file mode 100644 index 3e280446f..000000000 Binary files a/medcat-v1-tutorials/.github/.DS_Store and /dev/null differ diff --git a/medcat-v1/pyproject.toml b/medcat-v1/pyproject.toml index 4aeed43b5..08e8468be 100644 --- a/medcat-v1/pyproject.toml +++ b/medcat-v1/pyproject.toml @@ -3,3 +3,4 @@ requires = ["setuptools>=42", "setuptools_scm[toml]>=6.2", "wheel"] build-backend = "setuptools.build_meta" [tool.setuptools_scm] +root = "../" # adjust this relative to your package \ No newline at end of file