diff --git a/.codeclimate.yml b/.codeclimate.yml index 4b977238f5e5817b8b7fa585951962911adb0b75..c64e18a7aab61c4548309b8c9e41ace7ad91b780 100644 --- a/.codeclimate.yml +++ b/.codeclimate.yml @@ -4,6 +4,9 @@ --- version: "2" plugins: + structure: + exclude_patterns: + - documentation/variables.py pep8: enabled: true exclude_patterns: @@ -12,5 +15,61 @@ plugins: enabled: true shellcheck: enabled: true + file_types: + - "shell script" + - "bats script" + - "bash script" fixme: enabled: true + exclude_patterns: + - "/Dangerfile" + spellcheck: + enabled: true + config_options: + modules: + spell: + paths: + - "documentation" + exclude_patterns: + - GITIGNORE_CONTENTS + - "*.git" + - "*.png" + - "/documentation/conf.py" + - "/documentation/variables.py" + - "/documentation/Makefile" + - "/documentation/index.rst" + - "/documentation/requirements.txt" + - "__pycache__" + dict_path: "meta-cassini-config/qa-checks/cassini-dictionary" + yamllint: + enabled: true + exclude_patterns: + - ".rubocop.yml" + - ".eslintrc.yml" + headercheck: + enabled: true + config_options: + modules: + header: + paths: + - ROOT + exclude_patterns: + - GITIGNORE_CONTENTS + - "meta-ewaol/" + - "global_variables.env" + - "meta-cassini-config/qa-checks/cassini-dictionary" + - "/LICENSE.rst" + - "/CHANGELOG.md" + - "*.git" + - "*.gitignore" + - "*.pyc" + - "*.png" + - "*.cfg" + - "*.css" + - "*.scc" + - "*.patch" + - ".rubocop.yml" + - ".eslintignore" + - ".eslintrc.yml" + - ".csslintrc" + - "coffeelint.json" diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 8050cce82d1402ebe4508118cb1fb07658b0868a..932cbb9ee70d088221d04f09d30e006be131ea2f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -36,7 +36,7 @@ variables: # include jobs include: - project: $PIPELINE_TEMPLATE_PROJECT - ref: v0.0.8 + ref: v0.0.9 file: - gitlab-ci/common_gitlab-ci.yml - gitlab-ci/docker-image-base_gitlab-ci.yml @@ -49,7 +49,6 @@ include: - local: '.gitlab/ci/trigger-image-builds.yml' - local: '.gitlab/ci/docs-build.yml' - local: '.gitlab/ci/yocto-qa.yml' - - local: '.gitlab/ci/qa-checks.yml' # Job to regenerate the changelog when the project version number is changed changelog: diff --git a/.gitlab/ci/qa-checks.yml b/.gitlab/ci/qa-checks.yml deleted file mode 100644 index 3ee4c8adce860b713272210c2850f3db97471c69..0000000000000000000000000000000000000000 --- a/.gitlab/ci/qa-checks.yml +++ /dev/null @@ -1,67 +0,0 @@ -# Copyright (c) 2022 Arm Limited or its affiliates. All rights reserved. -# -# SPDX-License-Identifier: MIT ---- -.qa_checks_base: - extends: .resource-request - image: $CI_REGISTRY/$CI_PROJECT_PATH/$DOCKER_IMAGE_NAME:$DOCKER_IMAGE_TAG - stage: Build - variables: - DOCKER_IMAGE_NAME: utility-image - dependencies: [] - before_script: - - mkdir -p ~/.ssh - - eval "$(ssh-agent -s)" - - if [ -z "${SSH_PRIVATE_GITLAB}+x" ]; then - echo "${SSH_PRIVATE_GITLAB}" | tr -d '\r' | ssh-add - > /dev/null; - fi - - ssh-keyscan -t rsa ${CI_SERVER_HOST} >> ~/.ssh/known_hosts - # Ensure git is usable without prompts - - git config --global url.ssh://git@${CI_SERVER_HOST}.insteadOf - https://${CI_SERVER_HOST} - - git config --global user.email "you@example.com" - - git config --global user.name "Your Name" - - git clone https://git.gitlab.arm.com/ewaol/meta-ewaol.git - - pushd meta-ewaol - - git checkout kirkstone-dev - - popd - -spell-check: - extends: .qa_checks_base - script: - - ${CI_PROJECT_DIR}/meta-ewaol/tools/qa-checks/run-checks.py - --project_root=${CI_PROJECT_DIR} - --config=meta-cassini-config/qa-checks/qa-checks_config.yml - --log=debug - --check=spell - -header-check: - extends: .qa_checks_base - script: - - | - if git show --summary HEAD | grep -q '^Merge:\|^Author: embed-a'; then - echo "Merge Request detected skipping commit_msg check" - ${CI_PROJECT_DIR}/meta-ewaol/tools/qa-checks/run-checks.py \ - --project_root=${CI_PROJECT_DIR} \ - --config=meta-cassini-config/qa-checks/qa-checks_config.yml \ - --log=debug \ - --check=header - else - ${CI_PROJECT_DIR}/meta-ewaol/tools/qa-checks/run-checks.py \ - --project_root=${CI_PROJECT_DIR} \ - --config=meta-cassini-config/qa-checks/qa-checks_config.yml \ - --log=debug \ - --check=commit_msg \ - --check=header - fi - -code-check: - extends: .qa_checks_base - script: - - ${CI_PROJECT_DIR}/meta-ewaol/tools/qa-checks/run-checks.py - --project_root=${CI_PROJECT_DIR} - --config=meta-cassini-config/qa-checks/qa-checks_config.yml - --log=debug - --check=python - --check=shell - --check=yaml diff --git a/.gitlab/ci/trigger-image-builds.yml b/.gitlab/ci/trigger-image-builds.yml index 71e0f9f759532ddff3f0406c3c55f9f494eb29d0..a963ea2cb80948b5472bb3ba80bbc998280d4c8b 100644 --- a/.gitlab/ci/trigger-image-builds.yml +++ b/.gitlab/ci/trigger-image-builds.yml @@ -33,7 +33,7 @@ merge_jobs: cat << EOF > ${CI_JOB_FILE} include: - project: $PIPELINE_TEMPLATE_PROJECT - ref: v0.0.8 + ref: v0.0.9 file: - gitlab-ci/common_gitlab-ci.yml - gitlab-ci/lava-test-base_gitlab-ci.yml diff --git a/documentation/conf.py b/documentation/conf.py index 2882473d4524c4ed7c603fcab772d79610f4c93c..c708af5def6bf3578b374aa81da7b085f070f487 100644 --- a/documentation/conf.py +++ b/documentation/conf.py @@ -17,6 +17,7 @@ # Append the documentation directory to the path, so we can import variables import os import sys + sys.path.append(os.path.dirname(__file__)) # -- Project information ----------------------------------------------------- @@ -28,8 +29,6 @@ author = 'Arm Ltd.' # -- General configuration --------------------------------------------------- -#import sphinx_rtd_theme - # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. @@ -98,5 +97,5 @@ copybutton_only_copy_prompt_lines = True copybutton_copy_empty_lines = False copybutton_line_continuation_character = "\\" -import variables +import variables # noqa as has to follow the sys.path.append at top of file rst_prolog = variables.generate_rst_prolog() diff --git a/documentation/variables.py b/documentation/variables.py index 7cbb1e2983176517905789b830666279e90c1b9e..ab2e26de226ad982fbf8fda5dcbf7525cf0e217c 100644 --- a/documentation/variables.py +++ b/documentation/variables.py @@ -28,7 +28,7 @@ yocto_release = "kirkstone" yocto_doc_version = "4.0/" yocto_linux_version = "5.15" kas_version = "3.0.2" -cassini_version = "v0.1" +cassini_version = "v0.9.0" general_links = { "link:Yocto Project Documentation": f"https://docs.yoctoproject.org/{yocto_doc_version}", diff --git a/meta-cassini-config/qa-checks/qa-checks_config.yml b/meta-cassini-config/qa-checks/qa-checks_config.yml deleted file mode 100644 index 6db6124504a9d765b591d9dd762bd608570cf0ba..0000000000000000000000000000000000000000 --- a/meta-cassini-config/qa-checks/qa-checks_config.yml +++ /dev/null @@ -1,99 +0,0 @@ -# Copyright (c) 2022 Arm Limited or its affiliates. All rights reserved. -# -# SPDX-License-Identifier: MIT - -# Keywords: -# - ROOT: -# Root directory of the project's git repository (configurable via the -# --project_root script argument). -# - GITIGNORE_CONTENTS: -# This keyword is replaced by the contents of the repository's base -# .gitignore file. - -# Each QA-check module defines its required variables, which may be set here. -# If a required variable is not defined for a particular QA-check module, a -# value from the defaults section will be used. - ---- -defaults: - paths: - - ROOT - exclude_patterns: - - GITIGNORE_CONTENTS - - "*.git" - -modules: - commit_msg: - title_length: 80 - body_length: 80 - commits: "-1" - - doc_build: - # Use temporary directory - output_dir: "" - - header: - exclude_patterns: - - GITIGNORE_CONTENTS - - "meta-ewaol/" - - "global_variables.env" - - "meta-cassini-config/qa-checks/cassini-dictionary" - - "/LICENSE.rst" - - "/CHANGELOG.md" - - "*.git" - - "*.gitignore" - - "*.pyc" - - "*.png" - - "*.cfg" - - "*.css" - - "*.scc" - - "*.patch" - - layer: - kas_configs: - - "meta-cassini-config/kas/cassini.yml:\ - meta-cassini-config/kas/n1sdp.yml:\ - meta-cassini-config/kas/tests.yml" - test_layers: - - "meta-cassini-distro" - - "meta-cassini-tests" - - python: - file_types: - - "python script" - exclude_patterns: - - GITIGNORE_CONTENTS - - "meta-ewaol/" - - "*.git" - - "/documentation/variables.py" - pycodestyle_args: "" - - shell: - file_types: - - "shell script" - - "bats script" - - "bash script" - - spell: - paths: - - "README.md" - - "documentation" - exclude_patterns: - - GITIGNORE_CONTENTS - - "*.git" - - "*.png" - - "/documentation/conf.py" - - "/documentation/variables.py" - - "/documentation/Makefile" - - "/documentation/index.rst" - - "/documentation/requirements.txt" - dict_path: "meta-cassini-config/qa-checks/cassini-dictionary" - - yaml: - include_patterns: - - "*.yml" - - "*.yaml" - exclude_patterns: - - GITIGNORE_CONTENTS - - "*.git" - yamllint_args: "--strict"