-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into python-install-dir
- Loading branch information
Showing
40 changed files
with
997 additions
and
320 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
name: Run bootstrap tests | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
setup: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
strategy: ${{steps.load.outputs.strategy}} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
repository: colcon/ci | ||
- id: load | ||
run: | | ||
strategy=$(jq -c -M '.' strategy.json) | ||
echo "strategy=${strategy}" >> $GITHUB_OUTPUT | ||
bootstrap: | ||
needs: [setup] | ||
strategy: ${{ fromJson(needs.setup.outputs.strategy) }} | ||
runs-on: ${{ matrix.os }} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{matrix.python}} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install -U pip setuptools | ||
python -m pip install -U -e .[test] | ||
python -m pip uninstall -y colcon-core | ||
- name: Build and test | ||
run: | | ||
cd .. | ||
python ${{ github.workspace }}/bin/colcon build --paths ${{ github.workspace }} | ||
python ${{ github.workspace }}/bin/colcon test --paths ${{ github.workspace }} --return-code-on-test-failure | ||
- name: Use the installed package (Bash) | ||
if: ${{runner.os != 'windows'}} | ||
shell: bash | ||
run: | | ||
. ../install/local_setup.sh | ||
colcon --help | ||
- name: Use the installed package (CMD) | ||
if: ${{runner.os == 'windows'}} | ||
shell: cmd | ||
run: | | ||
call ..\install\local_setup.bat | ||
colcon --help |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Copyright 2016-2020 Dirk Thomas | ||
# Licensed under the Apache License, Version 2.0 | ||
|
||
__version__ = '0.15.0' | ||
__version__ = '0.16.1' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Copyright 2023 Open Source Robotics Foundation, Inc. | ||
# Licensed under the Apache License, Version 2.0 | ||
|
||
from distutils.command.install_data import install_data | ||
import os | ||
|
||
|
||
class symlink_data(install_data): # noqa: N801 | ||
"""Like install_data, but symlink files instead of copying.""" | ||
|
||
def copy_file(self, src, dst, **kwargs): # noqa: D102 | ||
if kwargs.get('link'): | ||
return super().copy_file(src, dst, **kwargs) | ||
|
||
if self.force: | ||
# os.symlink fails if the destination exists as a regular file | ||
if os.path.isdir(dst): | ||
target = os.path.join(dst, os.path.basename(src)) | ||
else: | ||
target = dst | ||
if os.path.exists(dst) and not os.path.islink(dst): | ||
os.remove(target) | ||
|
||
kwargs['link'] = 'sym' | ||
src = os.path.abspath(src) | ||
return super().copy_file(src, dst, **kwargs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.