Super-linter: Using GitHub Actions no report is found

Created on 18 Aug 2020  路  4Comments  路  Source: github/super-linter

Describe the bug
In GitHub Actions the action outputs that the reports have been generated to a folder.
However the GitHub Actions Artifact Upload can't find any report to upload.

To Reproduce
Steps to reproduce the behavior:

Setup the github action check

name: Quality Gate - Super-Linter 

on:
  pull_request:
    branches: [ master, develop ]

jobs:

  quality_check:
    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2

    - name: Super-Linter
      uses: github/[email protected]
      env: 
        GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        DEFAULT_WORKSPACE: /github/workspace
        OUTPUT_FOLDER: "QualityReports"
        OUTPUT_DETAILS: detailed

    - uses: actions/upload-artifact@v2
      with:
        name: SuperLinter-QualityReport
        path: '${{ github.workspace }}/QualityReports/'

Tried changing the the default workspace to several paths and no files were found.

Expected behavior
Upload Artifact Action finds and uploads the report generated to the folder defined in OUTPUT_FOLDER

Screenshots
image

image

Additional context
Super-Linter log

Run github/[email protected]
2020-08-18T10:25:33.0297510Z env:
2020-08-18T10:25:33.0298286Z   GITHUB_TOKEN: ***
2020-08-18T10:25:33.0298399Z   DEFAULT_WORKSPACE: /github/workspace
2020-08-18T10:25:33.0298489Z   OUTPUT_FOLDER: QualityReports
2020-08-18T10:25:33.0298577Z   OUTPUT_DETAILS: detailed
2020-08-18T10:25:33.0298649Z ##[endgroup]
2020-08-18T10:25:33.0316934Z ##[command]/usr/bin/docker run --name githubsuperlinterv3_293f91 --label 8118cb --workdir /github/workspace --rm -e GITHUB_TOKEN -e DEFAULT_WORKSPACE -e OUTPUT_FOLDER -e OUTPUT_DETAILS -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/PipelinePlayground/PipelinePlayground":"/github/workspace" github/super-linter:v3
2020-08-18T10:25:40.6810670Z --------------------------------------------------------------------------------
2020-08-18T10:25:40.6810869Z 
2020-08-18T10:25:40.6811149Z                               /@@#///////@@/(@//@%/(@.@(       @@
2020-08-18T10:25:40.6811446Z                           @@//////////////////////////////#*  @@@
2020-08-18T10:25:40.6811727Z                         @////@//(///////////@@@@@///@//@/@**//@@(
2020-08-18T10:25:40.6812005Z                       @///////@///////////////@@@@    (           @,
2020-08-18T10:25:40.6812286Z                      @/(&/@////////////////////                     @
2020-08-18T10:25:40.6812406Z                     @////////////////////////@@                      @
2020-08-18T10:25:40.6812525Z                   @%////////(//////////%/////&@            @@       *,@           ______________
2020-08-18T10:25:40.6812651Z              @@@@@/@/#/////(&//////////////////                       .@         /              \
2020-08-18T10:25:40.6812964Z         *@@@@@.    .%///(//@//////////////////&.   .@@,                 @%      / Don't mind me  \
2020-08-18T10:25:40.6813241Z       @@%           .&@&&/@.@//&/////(//////////    @@@@@@@@@         .. &@    / I'm just looking \
2020-08-18T10:25:40.6813561Z     @@%               @@@@@   @&/////////////////#   @/       V  @@/ ,@@@ @   <  for some trash... |
2020-08-18T10:25:40.6813686Z @@@%                   @@@@        .%@@@@//////#@ @   @@         @     .,.     \__________________/
2020-08-18T10:25:40.6813806Z                                           @@@/@(  (@@@@% @/\      %
2020-08-18T10:25:40.6813924Z                                            @@@@(    .     .@@/\   #
2020-08-18T10:25:40.6814035Z                                              @                  %@%
2020-08-18T10:25:40.6814107Z 
2020-08-18T10:25:40.6814367Z --------------------------------------------------------------------------------
2020-08-18T10:25:40.6844122Z 2020-08-18 10:25:40 [INFO  ]   ---------------------------------------------
2020-08-18T10:25:40.6872658Z 2020-08-18 10:25:40 [INFO  ]   --- GitHub Actions Multi Language Linter ----
2020-08-18T10:25:40.6901017Z 2020-08-18 10:25:40 [INFO  ]   ---------------------------------------------
2020-08-18T10:25:40.6930936Z 2020-08-18 10:25:40 [INFO  ]   ---------------------------------------------
2020-08-18T10:25:40.6956058Z 2020-08-18 10:25:40 [INFO  ]   The Super-Linter source code can be found at:
2020-08-18T10:25:40.6989365Z 2020-08-18 10:25:40 [INFO  ]    - https://github.com/github/super-linter
2020-08-18T10:25:40.7018646Z 2020-08-18 10:25:40 [INFO  ]   ---------------------------------------------
2020-08-18T10:25:40.7047502Z 2020-08-18 10:25:40 [INFO  ]   --------------------------------------------
2020-08-18T10:25:40.7072895Z 2020-08-18 10:25:40 [INFO  ]   Gathering GitHub information...
2020-08-18T10:25:40.7098862Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_SHA], value:[0381f5afe2d3e14aad226e0b0f6bef6c5e5ffe2c]
2020-08-18T10:25:40.7125642Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_WORKSPACE], value:[/github/workspace]
2020-08-18T10:25:40.7153200Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_EVENT_PATH], value:[/github/workflow/event.json]
2020-08-18T10:25:40.7604950Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_ORG], value:[brunomartinsprointelliflo]
2020-08-18T10:25:40.8082333Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_REPO], value:[PipelinePlayground]
2020-08-18T10:25:40.8109738Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_TOKEN]
2020-08-18T10:25:40.8136858Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_REPOSITORY], value:[brunomartinsprointelliflo/PipelinePlayground]
2020-08-18T10:25:40.8162252Z 2020-08-18 10:25:40 [INFO  ]   Successfully found:[GITHUB_RUN_ID], value:[213457159]
2020-08-18T10:25:40.8190132Z 2020-08-18 10:25:40 [INFO  ]   --------------------------------------------
2020-08-18T10:25:40.8222724Z 2020-08-18 10:25:40 [INFO  ]   Gathering user validation information...
2020-08-18T10:25:40.8271925Z 2020-08-18 10:25:40 [INFO  ]   - Validating ALL files in code base...
2020-08-18T10:25:43.2397116Z 2020-08-18 10:25:43 [WARN  ]   [editorconfig-checker]: Failed to get version info for:
2020-08-18T10:25:49.8086180Z 2020-08-18 10:25:49 [WARN  ]   No Ansible base directory found at:[/github/workspace/ansible]
2020-08-18T10:25:49.8748024Z 2020-08-18 10:25:49 [INFO  ]   
2020-08-18T10:25:49.8774048Z 2020-08-18 10:25:49 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:49.8801479Z 2020-08-18 10:25:49 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:49.8827545Z 2020-08-18 10:25:49 [INFO  ]   Linting [EDITORCONFIG] files...
2020-08-18T10:25:49.8855948Z 2020-08-18 10:25:49 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:49.8883241Z 2020-08-18 10:25:49 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:49.8942041Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.8966673Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/Properties/launchSettings.json]
2020-08-18T10:25:49.9028676Z 2020-08-18 10:25:49 [INFO  ]    - File:[launchSettings.json] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9076558Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9104251Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/WeatherForecast.cs]
2020-08-18T10:25:49.9153969Z 2020-08-18 10:25:49 [INFO  ]    - File:[WeatherForecast.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9202127Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9227388Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/appsettings.json]
2020-08-18T10:25:49.9278537Z 2020-08-18 10:25:49 [INFO  ]    - File:[appsettings.json] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9327980Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9353670Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/PipelinePlaygroundAPI.csproj]
2020-08-18T10:25:49.9409298Z 2020-08-18 10:25:49 [INFO  ]    - File:[PipelinePlaygroundAPI.csproj] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9461451Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9492814Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/Program.cs]
2020-08-18T10:25:49.9575561Z 2020-08-18 10:25:49 [INFO  ]    - File:[Program.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9631145Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9656369Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/Startup.cs]
2020-08-18T10:25:49.9706611Z 2020-08-18 10:25:49 [INFO  ]    - File:[Startup.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9757986Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9790111Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/appsettings.Development.json]
2020-08-18T10:25:49.9859503Z 2020-08-18 10:25:49 [INFO  ]    - File:[appsettings.Development.json] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:49.9909716Z 2020-08-18 10:25:49 [INFO  ]   ---------------------------
2020-08-18T10:25:49.9936899Z 2020-08-18 10:25:49 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/Controllers/WeatherForecastController.cs]
2020-08-18T10:25:49.9992250Z 2020-08-18 10:25:49 [INFO  ]    - File:[WeatherForecastController.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0047387Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0077331Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlayground.Logic/PipelinePlayground.Logic.csproj]
2020-08-18T10:25:50.0137835Z 2020-08-18 10:25:50 [INFO  ]    - File:[PipelinePlayground.Logic.csproj] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0196924Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0225894Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlayground.Logic/RocketLogic.cs]
2020-08-18T10:25:50.0287449Z 2020-08-18 10:25:50 [INFO  ]    - File:[RocketLogic.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0342883Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0370459Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlayground.Logic/SafeVaultLogic.cs]
2020-08-18T10:25:50.0426565Z 2020-08-18 10:25:50 [INFO  ]    - File:[SafeVaultLogic.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0508566Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0535692Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/test/XUnitTestProject/XUnitTestProject.csproj]
2020-08-18T10:25:50.0605069Z 2020-08-18 10:25:50 [INFO  ]    - File:[XUnitTestProject.csproj] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0661158Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0692579Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/test/XUnitTestProject/RocketLogicTest.cs]
2020-08-18T10:25:50.0754336Z 2020-08-18 10:25:50 [INFO  ]    - File:[RocketLogicTest.cs] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.0812583Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.0842599Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/README.md]
2020-08-18T10:25:50.0908409Z 2020-08-18 10:25:50 [INFO  ]    - File:[README.md] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.2309972Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.2337149Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/PipelinePlayground.sln]
2020-08-18T10:25:50.2399009Z 2020-08-18 10:25:50 [INFO  ]    - File:[PipelinePlayground.sln] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.2448895Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.2478739Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/SECURITY.md]
2020-08-18T10:25:50.2534591Z 2020-08-18 10:25:50 [INFO  ]    - File:[SECURITY.md] was linted with [editorconfig-checker] successfully
2020-08-18T10:25:50.4336019Z 2020-08-18 10:25:50 [INFO  ]   
2020-08-18T10:25:50.4362502Z 2020-08-18 10:25:50 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:50.4392896Z 2020-08-18 10:25:50 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:50.4419352Z 2020-08-18 10:25:50 [INFO  ]   Linting [JSON] files...
2020-08-18T10:25:50.4445793Z 2020-08-18 10:25:50 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:50.4472735Z 2020-08-18 10:25:50 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:50.4546699Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.4588850Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/Properties/launchSettings.json]
2020-08-18T10:25:50.6419560Z 2020-08-18 10:25:50 [INFO  ]    - File:[launchSettings.json] was linted with [jsonlint] successfully
2020-08-18T10:25:50.6471010Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.6500762Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/appsettings.json]
2020-08-18T10:25:50.8304727Z 2020-08-18 10:25:50 [INFO  ]    - File:[appsettings.json] was linted with [jsonlint] successfully
2020-08-18T10:25:50.8357537Z 2020-08-18 10:25:50 [INFO  ]   ---------------------------
2020-08-18T10:25:50.8387719Z 2020-08-18 10:25:50 [INFO  ]   File:[/github/workspace/src/PipelinePlaygroundAPI/appsettings.Development.json]
2020-08-18T10:25:51.0263401Z 2020-08-18 10:25:51 [INFO  ]    - File:[appsettings.Development.json] was linted with [jsonlint] successfully
2020-08-18T10:25:51.0511556Z 2020-08-18 10:25:51 [INFO  ]   
2020-08-18T10:25:51.0539454Z 2020-08-18 10:25:51 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:51.0568209Z 2020-08-18 10:25:51 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:51.0595552Z 2020-08-18 10:25:51 [INFO  ]   Linting [MARKDOWN] files...
2020-08-18T10:25:51.0621082Z 2020-08-18 10:25:51 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:51.0646683Z 2020-08-18 10:25:51 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:51.0698628Z 2020-08-18 10:25:51 [INFO  ]   ---------------------------
2020-08-18T10:25:51.0726419Z 2020-08-18 10:25:51 [INFO  ]   File:[/github/workspace/README.md]
2020-08-18T10:25:51.2829629Z 2020-08-18 10:25:51 [INFO  ]    - File:[README.md] was linted with [markdownlint] successfully
2020-08-18T10:25:51.2878644Z 2020-08-18 10:25:51 [INFO  ]   ---------------------------
2020-08-18T10:25:51.2906612Z 2020-08-18 10:25:51 [INFO  ]   File:[/github/workspace/SECURITY.md]
2020-08-18T10:25:51.5047184Z 2020-08-18 10:25:51 [INFO  ]    - File:[SECURITY.md] was linted with [markdownlint] successfully
2020-08-18T10:25:54.2438757Z 2020-08-18 10:25:54 [INFO  ]   /github/workspace/META6.json
2020-08-18T10:25:54.2828615Z 2020-08-18 10:25:54 [INFO  ]   
2020-08-18T10:25:54.2852927Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.2878590Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.2905196Z 2020-08-18 10:25:54 [INFO  ]   Linting [YAML] files...
2020-08-18T10:25:54.2930473Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.2954765Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3122282Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3148084Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3173668Z 2020-08-18 10:25:54 [INFO  ]   Generated reports:
2020-08-18T10:25:54.3202777Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3232037Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3261169Z 2020-08-18 10:25:54 [INFO  ]   Reports generated in folder /github/workspace/QualityReports
2020-08-18T10:25:54.3288105Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3314312Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3340547Z 2020-08-18 10:25:54 [INFO  ]   The script has completed
2020-08-18T10:25:54.3367658Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:54.3395165Z 2020-08-18 10:25:54 [INFO  ]   ----------------------------------------------
2020-08-18T10:25:55.4191787Z 2020-08-18 10:25:55 [NOTICE]   All file(s) linted successfully with no errors detected
2020-08-18T10:25:55.4219563Z 2020-08-18 10:25:55 [INFO  ]   ----------------------------------------------
bug

Most helpful comment

@brunomartinspro I think the OUTPUT_FORMAT parameter is required for a file to be generated.
https://github.com/github/super-linter/blob/f5752cfd452938932ae445c664284d17e981b1df/lib/linter.sh#L1028-L1038

I was running into the same problem and came across this issue (thanks for opening it!)

This excerpt works for me:

      - name: Check coding standards
        uses: github/super-linter@v3
        env:
          VALIDATE_ALL_CODEBASE: false
          VALIDATE_PHP_PHPCS: true
          DEFAULT_BRANCH: main
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          DISABLE_ERRORS: true
          OUTPUT_DETAILS: detailed
          OUTPUT_FORMAT: tap
      - name: Upload Report as an artifact
        uses: actions/upload-artifact@master
        with:
          name: linter-report
          path: "${{ github.workspace }}/super-linter.report/"

All 4 comments

@admiralAwkbar do reports only get generated if there is an error?
I am testing the latest version and i get the output on the build

2020-08-20 11:04:22 [INFO  ]   Reports generated in folder /github/workspace/QualityReports
2020-08-20 11:04:22 [INFO  ]   Contents of report folder:
ls: cannot access '/github/workspace/QualityReports': No such file or directory
2020-08-20 11:04:22 [INFO  ]   

@brunomartinspro remove the line: DEFAULT_WORKSPACE: /github/workspace

This will allow the internally defined workspace to be set.
then the ${{ github.worspace }} set in the next action will be able to pick it up properly

@admiralAwkbar creating the folder before running super-linter avoids the error but the folder is still empty after the analysis.
Is this the expected behavior if there are no errors?

2020-08-20 15:32:56 [INFO  ]   Reports generated in folder /github/workspace/QualityReports
2020-08-20 15:32:56 [INFO  ]   Contents of report folder:
2020-08-20 15:32:56 [INFO  ]   
2020-08-20 15:32:56 [INFO  ]   ----------------------------------------------
2020-08-20 15:32:56 [INFO  ]   ----------
name: Quality Gate - Super-Linter 

on:
  pull_request:
    branches: [ master, develop ]

jobs:

  quality_check:
    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2

    - name: Create QualityDirectory
      run: mkdir '${{ github.workspace }}/QualityReports/'

    - name: Super-Linter
      uses: github/[email protected]
      env: 
        GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        OUTPUT_FOLDER: "QualityReports"
        OUTPUT_DETAILS: detailed

    - uses: actions/upload-artifact@v2
      with:
        name: SuperLinter-QualityReport
        path: '${{ github.workspace }}/QualityReports/'

@brunomartinspro I think the OUTPUT_FORMAT parameter is required for a file to be generated.
https://github.com/github/super-linter/blob/f5752cfd452938932ae445c664284d17e981b1df/lib/linter.sh#L1028-L1038

I was running into the same problem and came across this issue (thanks for opening it!)

This excerpt works for me:

      - name: Check coding standards
        uses: github/super-linter@v3
        env:
          VALIDATE_ALL_CODEBASE: false
          VALIDATE_PHP_PHPCS: true
          DEFAULT_BRANCH: main
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
          DISABLE_ERRORS: true
          OUTPUT_DETAILS: detailed
          OUTPUT_FORMAT: tap
      - name: Upload Report as an artifact
        uses: actions/upload-artifact@master
        with:
          name: linter-report
          path: "${{ github.workspace }}/super-linter.report/"
Was this page helpful?
0 / 5 - 0 ratings