From 8a5878886e514fb358cc923f03013b4e19ed74e4 Mon Sep 17 00:00:00 2001 From: Andrej730 Date: Tue, 15 Sep 2026 11:18:14 +0500 Subject: [PATCH] conda\clean-old-version: add script metadata `bash -l` seems to be part of `setup-micromambda` --- .github/workflows/ci-ifcopenshell-conda-cleaner.yml | 13 +++---------- conda/clean-old-versions.py | 7 +++++++ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci-ifcopenshell-conda-cleaner.yml b/.github/workflows/ci-ifcopenshell-conda-cleaner.yml index b6f90666f3..c86e9a0555 100644 --- a/.github/workflows/ci-ifcopenshell-conda-cleaner.yml +++ b/.github/workflows/ci-ifcopenshell-conda-cleaner.yml @@ -18,20 +18,13 @@ env: jobs: activate: runs-on: ubuntu-latest - defaults: - run: - shell: bash -l {0} if: | github.repository == 'IfcOpenShell/IfcOpenShell' steps: - uses: actions/checkout@v7 - - uses: mamba-org/setup-micromamba@v3 # https://github.com/mamba-org/setup-micromamba - with: - environment-name: test-env - create-args: >- - python=3.11 - anaconda-client=1.12.3 + - name: Set up uv + uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7.6.0 - name: Run conda cleaner - run: python conda/clean-old-versions.py + run: uv run --script conda/clean-old-versions.py diff --git a/conda/clean-old-versions.py b/conda/clean-old-versions.py index 3fdb800663..6df49e7b40 100644 --- a/conda/clean-old-versions.py +++ b/conda/clean-old-versions.py @@ -1,3 +1,10 @@ +# /// script +# requires-python = ">=3.11" +# dependencies = [ +# "anaconda-client==1.12.3", +# ] +# /// + import os from binstar_client.errors import BinstarError