Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(colcon-build): nice-command to build-pre-command #310

Merged
merged 1 commit into from
Aug 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion colcon-build/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@
| token | false | The token for build dependencies. |
| include-eol-distros | false | If true, adds `--include-eol-distros` to `rosdep update`. |
| cache-key-element | false | This value is added to the github actions cache key. |
| nice-command | false | This command is prepended to the `colcon build` to avoid draining resources. |
| build-pre-command | false | This command is prepended to the `colcon build` to avoid draining resources. |
| colcon-parallel-workers-flag | false | Will be appended to the colcon build command to limit number of packages built in parallel. e.g. "--parallel-workers 3" |
| makeflags | false | Will be exported as MAKEFLAGS environment variable for colcon build step. e.g. "-j 4" |

Check warning on line 44 in colcon-build/README.md

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (makeflags)

Check warning on line 44 in colcon-build/README.md

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (MAKEFLAGS)

## Outputs

Expand Down
6 changes: 3 additions & 3 deletions colcon-build/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,16 @@
description: Will be part of the cache key
default: default
required: false
nice-command:
description: See `man nice` for details
build-pre-command:
description: Will be prepended to the colcon build command. e.g. "nice -n 19" or "taskset --cpu-list 0-2"

Check warning on line 30 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (taskset)
required: false
default: nice -n 19
colcon-parallel-workers-flag:
description: Will be appended to the colcon build command to limit number of packages built in parallel. e.g. "--parallel-workers 3"
default: ""
required: false
makeflags:

Check warning on line 37 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (makeflags)
description: Will be exported as MAKEFLAGS environment variable. e.g. "-j 4"

Check warning on line 38 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (MAKEFLAGS)
default: ""
required: false

Expand Down Expand Up @@ -92,9 +92,9 @@
cat /etc/nsswitch.conf
sed -e 's#hosts:\(.*\)dns\(.*\)#hosts:\1\2#g' -i.bak /etc/nsswitch.conf
cat /etc/nsswitch.conf
MAKEFLAGS="${{ inputs.makeflags }}"

Check warning on line 95 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (MAKEFLAGS)

Check warning on line 95 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (makeflags)
echo "MAKEFLAGS=$MAKEFLAGS" # for debugging

Check warning on line 96 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (MAKEFLAGS)

Check warning on line 96 in colcon-build/action.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (MAKEFLAGS)
${{ inputs.nice-command }} colcon build ${{ inputs.colcon-parallel-workers-flag }} \
${{ inputs.build-pre-command }} colcon build ${{ inputs.colcon-parallel-workers-flag }} \
--event-handlers console_cohesion+ \
--packages-above-and-dependencies ${{ inputs.target-packages }} \
--cmake-args -DCMAKE_BUILD_TYPE=${{ inputs.cmake-build-type }} \
Expand Down
Loading