diff --git a/README.md b/README.md index 73861d39..175dd3c1 100644 --- a/README.md +++ b/README.md @@ -209,6 +209,7 @@ But if you wish to select or exclude specific linters, we give you full control | **ENV VAR** | **Default Value** | **Notes** | | ---------------------------------- | ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **ACTIONS_RUNNER_DEBUG** | `false` | Flag to enable additional information about the linter, versions, and additional output. | +| **ANSIBLE_CONFIG_FILE** | `.ansible-lint.yml` | Filename for [Ansible-lint configuration](https://ansible-lint.readthedocs.io/en/latest/configuring.html#configuration-file) (ex: `.ansible-lint`, `.ansible-lint.yml`) | | **ANSIBLE_DIRECTORY** | `/ansible` | Flag to set the root directory for Ansible file location(s), relative to `DEFAULT_WORKSPACE`. Set to `.` to use the top-level of the `DEFAULT_WORKSPACE`. | | **CSS_FILE_NAME** | `.stylelintrc.json` | Filename for [Stylelint configuration](https://github.com/stylelint/stylelint) (ex: `.stylelintrc.yml`, `.stylelintrc.yaml`) | | **DEFAULT_BRANCH** | `master` | The name of the repository default branch. | diff --git a/lib/linter.sh b/lib/linter.sh index 1380ea9e..0b6f4bf0 100755 --- a/lib/linter.sh +++ b/lib/linter.sh @@ -74,7 +74,7 @@ export VERSION_FILE # Workaround # Rules files # ############### # shellcheck disable=SC2034 # Variable is referenced indirectly -ANSIBLE_FILE_NAME=".ansible-lint.yml" +ANSIBLE_FILE_NAME="${ANSIBLE_CONFIG_FILE:-.ansible-lint.yml}" # shellcheck disable=SC2034 # Variable is referenced indirectly ARM_FILE_NAME=".arm-ttk.psd1" # shellcheck disable=SC2034 # Variable is referenced indirectly