Skip to content

Commit

Permalink
Add one linter workflow for all branches
Browse files Browse the repository at this point in the history
  • Loading branch information
Wiktor-99 committed Aug 17, 2024
1 parent c1c3279 commit 50d454d
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 118 deletions.
29 changes: 0 additions & 29 deletions .github/workflows/build_and_test_humble.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,32 +23,3 @@ jobs:
- uses: ros-tooling/action-ros-ci@v0.3
with:
target-ros2-distro: humble
ament_lint_general:
name: ament_${{ matrix.linter }}
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-humble-ros-base-latest
strategy:
fail-fast: false
matrix:
linter: [xmllint, pep257]
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: ${{ matrix.linter }}
distribution: humble
package-name: human_detector
ament_flake8:
name: ament_flake8
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-humble-ros-base-latest
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: flake8
distribution: humble
package-name: human_detector
arguments: --config python_linter.flake8
29 changes: 0 additions & 29 deletions .github/workflows/build_and_test_iron.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,32 +23,3 @@ jobs:
- uses: ros-tooling/action-ros-ci@v0.3
with:
target-ros2-distro: iron
ament_lint_general:
name: ament_${{ matrix.linter }}
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-iron-ros-base-latest
strategy:
fail-fast: false
matrix:
linter: [xmllint, pep257]
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: ${{ matrix.linter }}
distribution: iron
package-name: human_detector
ament_flake8:
name: ament_flake8
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-iron-ros-base-latest
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: flake8
distribution: iron
package-name: human_detector
arguments: --config python_linter.flake8
30 changes: 0 additions & 30 deletions .github/workflows/build_and_test_jazzy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,33 +23,3 @@ jobs:
- uses: ros-tooling/action-ros-ci@v0.3
with:
target-ros2-distro: jazzy

ament_lint_general:
name: ament_${{ matrix.linter }}
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-noble-ros-jazzy-ros-base-latest
strategy:
fail-fast: false
matrix:
linter: [xmllint, pep257]
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: ${{ matrix.linter }}
distribution: jazzy
package-name: human_detector
ament_flake8:
name: ament_flake8
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-noble-ros-jazzy-ros-base-latest
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: flake8
distribution: jazzy
package-name: human_detector
arguments: --config python_linter.flake8
30 changes: 0 additions & 30 deletions .github/workflows/build_and_test_rolling.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,33 +23,3 @@ jobs:
- uses: ros-tooling/action-ros-ci@v0.3
with:
target-ros2-distro: rolling

ament_lint_general:
name: ament_${{ matrix.linter }}
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-noble-ros-rolling-ros-base-latest
strategy:
fail-fast: false
matrix:
linter: [xmllint, pep257]
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: ${{ matrix.linter }}
distribution: rolling
package-name: human_detector
ament_flake8:
name: ament_flake8
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-noble-ros-rolling-ros-base-latest
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: flake8
distribution: rolling
package-name: human_detector
arguments: --config python_linter.flake8
44 changes: 44 additions & 0 deletions .github/workflows/linters.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
name: ROS

on:
pull_request:
push:
branches:
- foxy*
- humble*
- iron*
- rolling*
- main*
workflow_dispatch:

jobs:
ament_lint_general:
name: ament_${{ matrix.linter }}
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-humble-ros-base-latest
strategy:
fail-fast: false
matrix:
linter: [xmllint, pep257]
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: ${{ matrix.linter }}
distribution: humble
package-name: human_detector
ament_flake8:
name: ament_flake8
runs-on: ubuntu-latest
container:
image: rostooling/setup-ros-docker:ubuntu-jammy-ros-humble-ros-base-latest
steps:
- uses: actions/checkout@v4
- uses: ros-tooling/action-ros-lint@v0.1
with:
linter: flake8
distribution: humble
package-name: human_detector
arguments: --config python_linter.flake8

0 comments on commit 50d454d

Please sign in to comment.