diff --git a/.github/actions/addon-linter/action.yml b/.github/actions/addon-linter/action.yml new file mode 100644 index 0000000000..ee70d0fba0 --- /dev/null +++ b/.github/actions/addon-linter/action.yml @@ -0,0 +1,32 @@ +--- +name: Home Assistant add-on linter compatibility +description: Normalize current app_config map names for the upstream add-on linter + +inputs: + path: + description: Path to the add-on directory + required: true + community: + description: Enable upstream community checks + required: false + default: "false" + +runs: + using: composite + steps: + - name: Prepare manifest for upstream linter + shell: bash + env: + SOURCE_PATH: ${{ inputs.path }} + DESTINATION_PATH: ${{ github.workspace }}/.addon-lint + run: | + set -euo pipefail + python3 "$GITHUB_ACTION_PATH/../../scripts/prepare_addon_lint_config.py" \ + "$SOURCE_PATH" \ + "$DESTINATION_PATH" + + - name: Run upstream Home Assistant add-on linter + uses: frenck/action-addon-linter@v2 + with: + path: ./.addon-lint + community: ${{ inputs.community }}