Skip to content

Commit e62746c

Browse files
committed
testpr: use rattler-build.
1 parent 8cd53ad commit e62746c

File tree

2 files changed

+21
-85
lines changed

2 files changed

+21
-85
lines changed

.github/testpr_environment.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

.github/workflows/testpr.yml

Lines changed: 21 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ jobs:
1414
matrix:
1515
os: [ubuntu-latest, macos-latest, macos-14, windows-2019]
1616
platform: [linux-64, linux-aarch64, osx-64, win-64, osx-arm64]
17+
environment: [beta]
1718
exclude:
1819
- os: ubuntu-latest
1920
platform: win-64
@@ -46,6 +47,15 @@ jobs:
4647
- os: windows-2019
4748
platform: osx-arm64
4849
steps:
50+
- uses: actions/checkout@v4
51+
with:
52+
persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal token
53+
fetch-depth: 0 # otherwise, you will failed to push refs to dest repo
54+
55+
- uses: prefix-dev/setup-pixi@v0.8.1
56+
with:
57+
environments: ${{ matrix.environment }}
58+
4959
# Workaround for https://github.com/RoboStack/ros-humble/pull/141#issuecomment-1941919816
5060
- name: Clean up PATH
5161
if: contains(matrix.os, 'windows')
@@ -55,16 +65,6 @@ jobs:
5565
# git in C:\Program Files\Git\bin is used by pip install git+
5666
dirs: 'C:\Program Files\Git\usr\bin;C:\Program Files\Git\bin;C:\Program Files\Git\cmd;C:\Program Files\Git\mingw64\bin'
5767

58-
- uses: actions/checkout@master
59-
- name: install micromamba
60-
uses: mamba-org/setup-micromamba@main
61-
with:
62-
environment-file: .github/testpr_environment.yml
63-
condarc: |
64-
channels:
65-
- robostack-staging
66-
- conda-forge
67-
6868
- shell: bash -l {0}
6969
if: matrix.platform == 'linux-aarch64'
7070
run: |
@@ -81,17 +81,6 @@ jobs:
8181
sudo apt-get update
8282
sudo apt-get install -y libgl1-mesa-dev libglu1-mesa-dev libx11-dev libxi-dev libxmu-dev
8383
84-
- shell: bash -l {0}
85-
run: |
86-
conda config --show channels | grep defaults && conda config --remove channels defaults
87-
conda info
88-
conda config --show
89-
micromamba install -y pip rospkg networkx "catkin_pkg>=0.4.16" "ruamel.yaml>=0.16.6" "rosdistro>=0.8.0" "empy>=3.3.4" boa
90-
- name: install vinca
91-
shell: bash -l {0}
92-
run: |
93-
# use no-deps for now, otherwise problems with ruamel.
94-
pip install git+https://github.com/RoboStack/vinca.git --no-deps
9584
# For some reason, the Strawberry perl's pkg-config is found
9685
# instead of the conda's one, so let's delete the /c/Strawberry directory
9786
- name: Debug pkg-config problem
@@ -121,82 +110,44 @@ jobs:
121110
shell: bash -l {0}
122111
if: steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-64'
123112
run: |
124-
git clean -fdx
125113
cp vinca_linux_64.yaml vinca.yaml
126-
vinca --platform linux-64
127-
ls
128-
cat recipe.yaml
114+
$HOME/.pixi/bin/pixi run -e beta -v vinca -m --platform linux-64
129115
- name: Generate recipes for linux-aarch64
130116
shell: bash -l {0}
131117
if: steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-aarch64'
132118
run: |
133-
git clean -fdx
134119
cp vinca_linux_aarch64.yaml vinca.yaml
135-
vinca --platform linux-aarch64
136-
ls
137-
cat recipe.yaml
120+
$HOME/.pixi/bin/pixi run -e beta -v vinca -m --platform linux-aarch64
138121
- name: Generate recipes for osx-64
139122
shell: bash -l {0}
140123
if: steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.os == 'macos-latest' && matrix.platform == 'osx-64'
141124
run: |
142-
git clean -fdx
143125
cp vinca_osx.yaml vinca.yaml
144-
vinca --platform osx-64
145-
ls
146-
cat recipe.yaml
126+
$HOME/.pixi/bin/pixi run -e beta -v vinca -m --platform osx-64
147127
- name: Generate recipes for osx-arm64
148128
shell: bash -l {0}
149129
if: steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.os == 'macos-14' && matrix.platform == 'osx-arm64'
150130
run: |
151-
git clean -fdx
152131
cp vinca_osx_arm64.yaml vinca.yaml
153-
vinca --platform osx-arm64
154-
ls
155-
cat recipe.yaml
132+
$HOME/.pixi/bin/pixi run -e beta -v vinca -m --platform osx-arm64
156133
- name: Generate recipes for win-64
157134
shell: bash -l {0}
158135
if: steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.os == 'windows-2019' && matrix.platform == 'win-64'
159136
run: |
160-
git clean -fdx
161137
cp vinca_win.yaml vinca.yaml
162-
vinca --platform win-64
163-
ls
164-
cat recipe.yaml
138+
$HOME/.pixi/bin/pixi run -e beta -v vinca -m --platform win-64
139+
165140
- name: Check if there are packages to be built
166141
id: newrecipecheck
167142
shell: bash -l {0}
168143
run: |
169144
# continue on error
170145
set +e
171-
grep -q "outputs: \[\]" recipe.yaml > /dev/null
146+
grep -qr "outputs: \[\]" recipes/ > /dev/null
172147
echo "::set-output name=RECIPE_CREATED::${?}"
173-
- name: Build recipes for linux-64
174-
shell: bash -l {0}
175-
run: |
176-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
177-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
178-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-64'
179-
- name: Build recipes for linux-aarch64
180-
shell: bash -l {0}
181-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-aarch64'
182-
run: |
183-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=linux-aarch64
184-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=linux-aarch64
185-
- name: Build recipes for osx-64
186-
shell: bash -l {0}
187-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.os == 'macos-latest' && matrix.platform == 'osx-64'
188-
run: |
189-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
190-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
191-
- name: Build recipes for osx-arm64
192-
shell: bash -l {0}
193-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.os == 'macos-14' && matrix.platform == 'osx-arm64'
194-
run: |
195-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=osx-arm64
196-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
197-
- name: Build recipes for win-64
148+
- name: Build recipes
149+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1
198150
shell: bash -l {0}
199-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.os == 'windows-2019' && matrix.platform == 'win-64'
200151
run: |
201-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
202-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
152+
cp -a additional_recipes/* recipes/
153+
$HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes/ -m ./conda_build_config.yaml --skip-existing

0 commit comments

Comments
 (0)