Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace `PWD` with correct `pwd`. Incorrect: ```sh $ docker run --rm -v /var/run/docker.sock:/var/run/docker.sock:rw -v $(PWD):/tmp/lint:rw oxsecurity/megalinter:latest PWD: command not found Skipped setting git safe.directory DEFAULT_WORKSPACE: ... Setting git safe.directory default: /github/workspace ... Setting git safe.directory to /tmp/lint ... [MegaLinter init] ONE-SHOT RUN Traceback (most recent call last): File "/usr/local/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/local/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/megalinter/run.py", line 9, in <module> linter = megalinter.Megalinter({"cli": True}) File "/megalinter/MegaLinter.py", line 56, in __init__ self.workspace = self.get_workspace() File "/megalinter/MegaLinter.py", line 361, in get_workspace raise FileNotFoundError( FileNotFoundError: [Context] Unable to find a workspace to lint DEFAULT_WORKSPACE: GITHUB_WORKSPACE: ``` Corrected ```sh $ docker run --rm -v /var/run/docker.sock:/var/run/docker.sock:rw -v $(pwd):/tmp/lint:rw oxsecurity/megalinter:latest Skipped setting git safe.directory DEFAULT_WORKSPACE: ... Setting git safe.directory default: /github/workspace ... Setting git safe.directory to /tmp/lint ... [MegaLinter init] ONE-SHOT RUN [config] Environment variables only (no config file found in /tmp/lint) ---------------------------------------------------------------------------------------------------- ------------------------------------ MegaLinter, by OX Security ------------------------------------ ---------------------------------------------------------------------------------------------------- - Image Creation Date: 2023-01-07T10:05:11Z - Image Revision: 8fd433c - Image Version: v6 ---------------------------------------------------------------------------------------------------- The MegaLinter documentation can be found at: - https://megalinter.io/latest ... ```
- Loading branch information