Skip to content

problem matcher not found in Docker action #25807

Answered by dnorth98
dnorth98 asked this question in Actions
Discussion options

You must be logged in to vote

Just solved this.  It’s not obvious but the matcher config json must be available OUTSIDE the action container.  What I ended up doing was copying it into the current workspace. So in my entrypoint.sh file:

matcher_path=`pwd`/rubocop-problem-matcher.json

cp /rubocop-problem-matcher.json "$matcher_path"

echo "::add-matcher::rubocop-problem-matcher.json"

(needs a bit of a cleanup).  The key thing is that the workspace path is mapped in the docker container so when you echo the add-matcher command, you cannot use the full path of the file (since that is inside the container).

But…it works!  Have to say, problem matchers are BRILLIANT and vastly simplify the process of getting annotations ba…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant