Skip to content

Commit

Permalink
dev: Update markdowlint-cli2 to 5.0.1 (linkerd#1892)
Browse files Browse the repository at this point in the history
* Update devcontainer to v26
* Add a `just markdownlint` recipe
* Add a `shellcheck` workflow
* Address lints

Signed-off-by: Oliver Gould <ver@buoyant.io>

Signed-off-by: Oliver Gould <ver@buoyant.io>
  • Loading branch information
olix0r authored Aug 15, 2022
1 parent ef39d86 commit c0f5bcb
Show file tree
Hide file tree
Showing 19 changed files with 54 additions and 40 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "linkerd2-proxy",
"image": "ghcr.io/linkerd/dev:v24",
"image": "ghcr.io/linkerd/dev:v26",
"extensions": [
"DavidAnson.vscode-markdownlint",
"kokakiwi.vscode-just",
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/on-create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ cargo +nightly install cargo-fuzz

scurl https://run.linkerd.io/install-edge | sh
mkdir -p "$HOME/bin"
(cd "$HOME/bin" && ln -s "$HOME/.linkerd2/bin/linkerd")
(cd "$HOME/bin" && ln -s "$HOME/.linkerd2/bin/linkerd" .)
2 changes: 1 addition & 1 deletion .github/fuzzers-list.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ find_fuzz_dir() {

for file in "$@" ; do
if [ "$file" = .github/workflows/fuzzers.yml ] || [ "$file" = .github/fuzzers-list.sh ]; then
find * -type d -name fuzz
find linkerd -type d -name fuzz
break
fi
find_fuzz_dir "$file"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
actionlint:
runs-on: ubuntu-20.04
timeout-minutes: 10
container: ghcr.io/linkerd/dev:v24-tools
container: ghcr.io/linkerd/dev:v26-tools
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- name: Run actionlint
Expand All @@ -25,7 +25,7 @@ jobs:
devcontainer-versions:
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-tools
container: ghcr.io/linkerd/dev:v26-tools
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- name: Scan workflows for other Devcontainer image versions
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ permissions:
jobs:
build:
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
timeout-minutes: 20
continue-on-error: true
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
check-all:
timeout-minutes: 20
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-each.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
needs: list-changed-crates
timeout-minutes: 20
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
strategy:
matrix:
crate: ${{ fromJson(needs.list-changed-crates.outputs.crates) }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 30
container:
image: docker://ghcr.io/linkerd/dev:v24-rust
image: docker://ghcr.io/linkerd/dev:v26-rust
options: --security-opt seccomp=unconfined # 🤷
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
deprecated:
timeout-minutes: 20
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
test:
timeout-minutes: 20
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
clippy:
timeout-minutes: 10
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand All @@ -30,15 +30,15 @@ jobs:
fmt:
timeout-minutes: 10
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just check-fmt

docs:
timeout-minutes: 10
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/markdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- uses: DavidAnson/markdownlint-cli2-action@d199b6e1b89360c71e0c21eac02f7965faf07ba6
- uses: DavidAnson/markdownlint-cli2-action@e3969ef4ed874458f4b66d4631f78fff7717012c
with:
globs: "**/*.md"
2 changes: 1 addition & 1 deletion .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ permissions:
jobs:
build:
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
timeout-minutes: 20
continue-on-error: true
steps:
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/shellcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: markdown

permissions:
contents: read

on:
pull_request:
paths:
- '**/*.sh'
- .github/workflows/shellcheck.yml

jobs:
markdownlint:
timeout-minutes: 5
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v26-tools
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just shellcheck
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
meshtls:
timeout-minutes: 10
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand All @@ -42,7 +42,7 @@ jobs:
unit:
timeout-minutes: 10
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-rust
container: ghcr.io/linkerd/dev:v26-rust
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- run: just fetch
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/toolchain.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
workflows:
runs-on: ubuntu-latest
container: ghcr.io/linkerd/dev:v24-tools
container: ghcr.io/linkerd/dev:v26-tools
steps:
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
- shell: bash
Expand Down
7 changes: 2 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
## Getting Help

If you have a question about Linkerd2 or have encountered problems using it,
start by [asking a question in the forums][discourse] or join us in the
start by [asking a question in the forums][discussions] or join us in the
[#linkerd2 Slack channel][slack].

## Certificate of Origin
Expand Down Expand Up @@ -99,9 +99,6 @@ Describe the modifications you've made.
Describe the testing you've done to validate your change. Performance-related
changes should include before- and after- benchmark results.

[discourse]: https://discourse.linkerd.io/c/conduit
[governance]: GOVERNANCE.md
[discussions]: https://github.com/linkerd/linkerd2/discussions/new
[issue]: https://github.com/linkerd/linkerd2/issues/new
[maintainers]: MAINTAINERS.md
[members]: https://github.com/orgs/linkerd/people
[slack]: http://slack.linkerd.io/
25 changes: 10 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@

![linkerd2][logo]

<!-- TODO [![Build Status][ci-badge]][ci] -->
[![GitHub license][license-badge]](LICENSE)
[![GitHub license](https://img.shields.io/github/license/linkerd/linkerd2-proxy.svg)](LICENSE)
[![Slack Status][slack-badge]][slack]

This repo contains the transparent proxy component of [Linkerd2][linkerd2].
Expand Down Expand Up @@ -99,19 +98,15 @@ specific language governing permissions and limitations under the License.

<!-- refs -->
[cargo]: https://github.com/rust-lang/cargo/
[ci]: https://travis-ci.org/linkerd/linkerd2-proxy
<!-- TODO [ci-badge]: https://travis-ci.org/linkerd/linkerd2-proxy.svg?branch=master -->
[cncf]: https://cncf.io/
[coc]: https://github.com/linkerd/linkerd/wiki/Linkerd-code-of-conduct
[k8s]: https://kubernetes.io/
[license-badge]: https://img.shields.io/github/license/linkerd/linkerd2.svg
[linkerd1]: https://github.com/linkerd/linkerd
[linkerd2]: https://github.com/linkerd/linkerd2
[linkerd2-proxy-api]: https://github.com/linkerd/linkerd2-proxy-api
[loadbalancing]: https://linkerd.io/features/load-balancing/
[logo]: https://user-images.githubusercontent.com/9226/33582867-3e646e02-d90c-11e7-85a2-2e238737e859.png
[prom]: https://prometheus.io/
[rust]: https://www.rust-lang.org/
[slack-badge]: https://slack.linkerd.io/badge.svg
[slack]: https://slack.linkerd.io
[twitter]: https://twitter.com/linkerd/
[linkerd1]: <https://github.com/linkerd/linkerd>
[linkerd2]: <https://github.com/linkerd/linkerd2>
[linkerd2-proxy-api]: <https://github.com/linkerd/linkerd2-proxy-api>
[loadbalancing]: <https://linkerd.io/2.11/features/load-balancing/>
[logo]: <https://user-images.githubusercontent.com/9226/33582867-3e646e02-d90c-11e7-85a2-2e238737e859.png>
[prom]: <https://prometheus.io/>
[rust]: <https://www.rust-lang.org/>
[slack-badge]: <https://slack.linkerd.io/badge.svg>
[slack]: <https://slack.linkerd.io>
5 changes: 4 additions & 1 deletion justfile
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ check-fmt:
{{ cargo }} fmt -- --check

# Run all lints
lint: shellcheck clippy doc
lint: shellcheck markdownlint clippy doc

# Lints all shell scripts in the repo.
shellcheck:
Expand All @@ -111,6 +111,9 @@ shellcheck:
echo shellcheck $files
shellcheck $files

markdownlint:
markdownlint-cli2 '**/*.md' '!target'

check *flags:
{{ cargo }} check --workspace --all-targets --frozen {{ flags }} {{ _fmt }}

Expand Down

0 comments on commit c0f5bcb

Please sign in to comment.