From cb41ae47fa84606d57aa90f7f6d01767ffdb7b66 Mon Sep 17 00:00:00 2001 From: Lucas Gravley <29484535+admiralAwkbar@users.noreply.github.com> Date: Tue, 25 Aug 2020 09:05:23 -0500 Subject: [PATCH] adding feature --- Dockerfile | 2 ++ README.md | 1 + lib/linter.sh | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 297bd644..9afa3856 100644 --- a/Dockerfile +++ b/Dockerfile @@ -260,12 +260,14 @@ RUN cd ~ && touch .chktexrc ########################################### ENV ACTIONS_RUNNER_DEBUG=${ACTIONS_RUNNER_DEBUG} \ ANSIBLE_DIRECTORY=${ANSIBLE_DIRECTORY} \ + CSS_FILE_NAME=${CSS_FILE_NAME} \ DEFAULT_BRANCH=${DEFAULT_BRANCH} \ DISABLE_ERRORS=${DISABLE_ERRORS} \ GITHUB_EVENT_PATH=${GITHUB_EVENT_PATH} \ GITHUB_SHA=${GITHUB_SHA} \ GITHUB_TOKEN=${GITHUB_TOKEN} \ GITHUB_WORKSPACE=${GITHUB_WORKSPACE} \ + JAVASCRIPT_ES_CONFIG_FILE=${JAVASCRIPT_ES_CONFIG_FILE} \ LINTER_RULES_PATH=${LINTER_RULES_PATH} \ LOG_FILE=${LOG_FILE} \ LOG_LEVEL=${LOG_LEVEL} \ diff --git a/README.md b/README.md index 7177cef7..6e140843 100644 --- a/README.md +++ b/README.md @@ -174,6 +174,7 @@ But if you wish to select or exclude specific linters, we give you full control | -------------------------------- | --------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **ACTIONS_RUNNER_DEBUG** | `false` | Flag to enable additional information about the linter, versions, and additional output. | | **ANSIBLE_DIRECTORY** | `/ansible` | Flag to set the root directory for Ansible file location(s). | +| **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. | | **DEFAULT_WORKSPACE** | `/tmp/lint` | The location containing files to lint if you are running locally. | | **DISABLE_ERRORS** | `false` | Flag to have the linter complete with exit code 0 even if errors were detected. | diff --git a/lib/linter.sh b/lib/linter.sh index 1475c8f6..d7c39267 100755 --- a/lib/linter.sh +++ b/lib/linter.sh @@ -40,7 +40,7 @@ CLOJURE_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${CLOJURE_FILE_NAME}" # Path to COFFEE_FILE_NAME='.coffee-lint.json' # Name of the file COFFEESCRIPT_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${COFFEE_FILE_NAME}" # Path to the coffeescript lint rules # CSS Vars -CSS_FILE_NAME='.stylelintrc.json' # Name of the file +CSS_FILE_NAME="${CSS_FILE_NAME:-.stylelintrc.json}" # Name of the file CSS_LINTER_RULES="${DEFAULT_RULES_LOCATION}/${CSS_FILE_NAME}" # Path to the CSS lint rules # Dart Vars DART_FILE_NAME='analysis_options.yml' # Name of the file