Skip to content

Commit

Permalink
Fix CUSTOM_REPOLINT_FILE
Browse files Browse the repository at this point in the history
closes #2
  • Loading branch information
JeroenKnoops committed Nov 10, 2020
1 parent 1dc24f0 commit 887c830
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ RUN apk add --no-cache \
git \
&& rm -rf /var/cache/apk/*

COPY repolint.json /repolinter/
COPY repolint.yml /repolinter/

COPY entrypoint.sh /entrypoint.sh

Expand Down
8 changes: 6 additions & 2 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@ npm install -g todogroup/repolinter

if [ -z "$CUSTOM_REPOLINT_FILE" ]; then
echo "[INFO] Insert default configuration"
cp /repolinter/repolint.json .
cp /repolinter/repolint.yml .
REPOLINT_FILE=repolint.yml
else
echo "[INFO] Insert CUSTOM configuration"
REPOLINT_FILE=$CUSTOM_REPOLINT_FILE
fi

echo "[INFO] Executing:"
echo "[INFO] repolinter $*"
sh -c "repolinter $*"
sh -c "repolinter --rulesetFile $REPOLINT_FILE $*"

0 comments on commit 887c830

Please sign in to comment.