From c4c8d3aaf43d2a7fa8b896e0d9ad1416ddb26dfe Mon Sep 17 00:00:00 2001 From: MoritzWeber Date: Tue, 6 Feb 2024 14:37:11 +0100 Subject: [PATCH] chore: Apply prettier layout globally --- .github/dependabot.yml | 32 +++++----- .github/workflows/codeql-analysis.yml | 59 +++++++++---------- .github/workflows/lint.yml | 8 +-- .github/workflows/push.yml | 4 +- .github/workflows/tests.yml | 6 +- .gitlab-ci.yml | 12 ++-- docs/.prettierrc.yaml => .prettierrc.yaml | 2 +- CONTRIBUTING.md | 14 +++-- .../capellacollab/config/config_schema.yaml | 12 ++-- frontend/src/app/app-routing.module.ts | 5 +- 10 files changed, 79 insertions(+), 75 deletions(-) rename docs/.prettierrc.yaml => .prettierrc.yaml (89%) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 1f285ee4c..1109c07fd 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -4,30 +4,30 @@ version: 2 updates: # Backend - - package-ecosystem: "pip" - directory: "/backend" + - package-ecosystem: 'pip' + directory: '/backend' schedule: - interval: "weekly" + interval: 'weekly' # Frontend - - package-ecosystem: "npm" - directory: "/frontend" + - package-ecosystem: 'npm' + directory: '/frontend' schedule: - interval: "weekly" + interval: 'weekly' groups: angular: patterns: - - "@angular*" + - '@angular*' update-types: - - "major" - - "minor" - - "patch" + - 'major' + - 'minor' + - 'patch' # Capella Dockerimages - - package-ecosystem: "gitsubmodule" - directory: "/" + - package-ecosystem: 'gitsubmodule' + directory: '/' schedule: - interval: "daily" + interval: 'daily' # Github Actions - - package-ecosystem: "github-actions" - directory: "/" + - package-ecosystem: 'github-actions' + directory: '/' schedule: - interval: "daily" + interval: 'daily' diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index ae274b74e..ec87e05e7 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -12,14 +12,14 @@ # the `language` matrix defined below to confirm you have the correct set of # supported CodeQL languages. # -name: "CodeQL" +name: 'CodeQL' on: push: - branches: [ main ] + branches: [main] pull_request: # The branches below must be a subset of the branches above - branches: [ main ] + branches: [main] schedule: - cron: '24 12 * * 3' @@ -35,41 +35,40 @@ jobs: strategy: fail-fast: false matrix: - language: [ 'javascript', 'python' ] + language: ['javascript', 'python'] # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support steps: - - name: Checkout repository - uses: actions/checkout@v4 + - name: Checkout repository + uses: actions/checkout@v4 - # Initializes the CodeQL tools for scanning. - - name: Initialize CodeQL - uses: github/codeql-action/init@v3 - with: - languages: ${{ matrix.language }} - # If you wish to specify custom queries, you can do so here or in a config file. - # By default, queries listed here will override any specified in a config file. - # Prefix the list here with "+" to use these queries and those in the config file. + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v3 + with: + languages: ${{ matrix.language }} + # If you wish to specify custom queries, you can do so here or in a config file. + # By default, queries listed here will override any specified in a config file. + # Prefix the list here with "+" to use these queries and those in the config file. - # 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 - # queries: security-extended,security-and-quality + # 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 + # queries: security-extended,security-and-quality + # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). + # If this step fails, then you should remove it and run the build manually (see below) + - name: Autobuild + uses: github/codeql-action/autobuild@v3 - # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). - # If this step fails, then you should remove it and run the build manually (see below) - - name: Autobuild - uses: github/codeql-action/autobuild@v3 + # ℹī¸ Command-line programs to run using the OS shell. + # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun - # ℹī¸ Command-line programs to run using the OS shell. - # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun + # If the Autobuild fails above, remove it and uncomment the following three lines. + # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. - # If the Autobuild fails above, remove it and uncomment the following three lines. - # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. + # - run: | + # echo "Run, Build Application using script" + # ./location_of_script_within_repo/buildscript.sh - # - run: | - # echo "Run, Build Application using script" - # ./location_of_script_within_repo/buildscript.sh - - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v3 + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 4f4235d2e..327050608 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -4,10 +4,10 @@ name: lint on: push: - branches: ["**"] - tags: ["v*.*.*"] + branches: ['**'] + tags: ['v*.*.*'] pull_request: - branches: [ main ] + branches: [main] jobs: helm-chart: @@ -41,7 +41,7 @@ jobs: with: cache: pip cache-dependency-path: ./backend/pyproject.toml - python-version: "3.11" + python-version: '3.11' - name: Install pre-commit run: |- python -m pip install pre-commit diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index faa6bf5ed..7cbe12a18 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -4,8 +4,8 @@ name: push on: push: - branches: ["**"] - tags: ["v*.*.*"] + branches: ['**'] + tags: ['v*.*.*'] pull_request: branches: [main] diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 7072b7366..14228f867 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -4,8 +4,8 @@ name: tests on: push: - branches: ["**"] - tags: ["v*.*.*"] + branches: ['**'] + tags: ['v*.*.*'] pull_request: branches: [main] @@ -23,7 +23,7 @@ jobs: with: cache: pip cache-dependency-path: ./backend/pyproject.toml - python-version: "3.11" + python-version: '3.11' - name: Install dependencies run: | pip install -e "./backend[dev]" diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7c0f7033a..4fea22ad3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,19 +8,19 @@ staging: - when: manual variables: TARGET: staging - REVISION: "$CI_COMMIT_REF_NAME" - DOCKER_BUILD_ARGS: "" # Enable Docker build cache + REVISION: '$CI_COMMIT_REF_NAME' + DOCKER_BUILD_ARGS: '' # Enable Docker build cache trigger: - project: "$DEPLOYMENT_GITLAB_REPOSITORY" + project: '$DEPLOYMENT_GITLAB_REPOSITORY' strategy: depend production: rules: # For tags, build for the production environment - - if: "$CI_COMMIT_TAG != null" + - if: '$CI_COMMIT_TAG != null' variables: TARGET: production - REVISION: "$CI_COMMIT_REF_NAME" + REVISION: '$CI_COMMIT_REF_NAME' trigger: - project: "$DEPLOYMENT_GITLAB_REPOSITORY" + project: '$DEPLOYMENT_GITLAB_REPOSITORY' strategy: depend diff --git a/docs/.prettierrc.yaml b/.prettierrc.yaml similarity index 89% rename from docs/.prettierrc.yaml rename to .prettierrc.yaml index 67a4f9970..2a26b2257 100644 --- a/docs/.prettierrc.yaml +++ b/.prettierrc.yaml @@ -1,7 +1,7 @@ # SPDX-FileCopyrightText: Copyright DB InfraGO AG and contributors # SPDX-License-Identifier: Apache-2.0 -trailingComma: "es5" +trailingComma: 'es5' tabWidth: 2 semi: false singleQuote: true diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f44e8ddf2..1a4a0d5a7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -10,10 +10,12 @@ Thanks for your interest in our project. Contributions are always welcome! We are committed to fostering a welcoming, respectful, and harassment-free environment. Be kind! -If you have questions, ideas or want to report a bug, feel free to [open an -issue](/../../issues). Or go ahead and [open a pull request](/../../pulls) to contribute -code. In order to reduce the burden on our maintainers, please make sure that -your code follows our style guidelines. +If you have questions, ideas or want to report a bug, feel free to +[open an issue](/../../issues). Or go ahead and +[open a pull request](/../../pulls) to contribute code. In order to reduce the +burden on our maintainers, please make sure that your code follows our style +guidelines. -We provide a developer documentation. There you will also find information -on how to set up a local environment: [Developer Documentation](https://dsd-dbs.github.io/capella-collab-manager/development/) +We provide a developer documentation. There you will also find information on +how to set up a local environment: +[Developer Documentation](https://dsd-dbs.github.io/capella-collab-manager/development/) diff --git a/backend/capellacollab/config/config_schema.yaml b/backend/capellacollab/config/config_schema.yaml index 98b2b2473..e19ee008d 100644 --- a/backend/capellacollab/config/config_schema.yaml +++ b/backend/capellacollab/config/config_schema.yaml @@ -111,7 +111,7 @@ properties: host: type: string port: - type: ["number", "string"] + type: ['number', 'string'] scheme: type: string wildcardHost: @@ -177,21 +177,21 @@ properties: tokenIssuance: type: - string - - "null" + - 'null' authorization: type: - string - - "null" + - 'null' wellKnown: type: - string - - "null" + - 'null' audience: type: string scopes: type: - array - - "null" + - 'null' items: type: string enum: @@ -208,7 +208,7 @@ properties: secret: type: - string - - "null" + - 'null' redirectURI: type: string jwt: diff --git a/frontend/src/app/app-routing.module.ts b/frontend/src/app/app-routing.module.ts index 5b3991907..e65b7f90a 100644 --- a/frontend/src/app/app-routing.module.ts +++ b/frontend/src/app/app-routing.module.ts @@ -363,7 +363,10 @@ const routes: Routes = [ }, { path: 'tool/:toolID', - data: { breadcrumb: 'Tools', redirect: '/settings/core/tools' }, + data: { + breadcrumb: 'Tools', + redirect: '/settings/core/tools', + }, children: [ { path: '',