Skip to content

Commit a91f7ba

Browse files
committed
Updates Makefile to clean up containers
1 parent 5f66634 commit a91f7ba

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

GNUmakefile

+4-4
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,15 @@ docs-lint:
7474
echo "Unexpected misspelling found in docs files."; \
7575
echo "To automatically fix the misspelling, run 'make docs-lint-fix' and commit the changes."; \
7676
exit 1)
77-
@docker run -v $(PWD):/markdown 06kellyjac/markdownlint-cli docs/ || (echo; \
77+
@docker run --rm -v $(PWD):/markdown 06kellyjac/markdownlint-cli docs/ || (echo; \
7878
echo "Unexpected issues found in docs Markdown files."; \
7979
echo "To apply any automatic fixes, run 'make docs-lint-fix' and commit the changes."; \
8080
exit 1)
8181

8282
docs-lint-fix:
8383
@echo "==> Applying automatic docs linter fixes..."
8484
@misspell -w -source=text docs/
85-
@docker run -v $(PWD):/markdown 06kellyjac/markdownlint-cli --fix docs/
85+
@docker run --rm -v $(PWD):/markdown 06kellyjac/markdownlint-cli --fix docs/
8686

8787
docscheck:
8888
@tfproviderdocs check \
@@ -155,7 +155,7 @@ website-lint:
155155
echo "Unexpected mispelling found in website files."; \
156156
echo "To automatically fix the misspelling, run 'make website-lint-fix' and commit the changes."; \
157157
exit 1)
158-
@docker run -v $(PWD):/markdown 06kellyjac/markdownlint-cli website/docs/ || (echo; \
158+
@docker run --rm -v $(PWD):/markdown 06kellyjac/markdownlint-cli website/docs/ || (echo; \
159159
echo "Unexpected issues found in website Markdown files."; \
160160
echo "To apply any automatic fixes, run 'make website-lint-fix' and commit the changes."; \
161161
exit 1)
@@ -168,7 +168,7 @@ website-lint:
168168
website-lint-fix:
169169
@echo "==> Applying automatic website linter fixes..."
170170
@misspell -w -source=text website/
171-
@docker run -v $(PWD):/markdown 06kellyjac/markdownlint-cli --fix website/docs/
171+
@docker run --rm -v $(PWD):/markdown 06kellyjac/markdownlint-cli --fix website/docs/
172172
@terrafmt fmt ./website --pattern '*.markdown'
173173

174174
semgrep:

0 commit comments

Comments
 (0)