diff --git a/.conda/recipe.yaml b/.conda/recipe.yaml index 0783f994..11109739 100644 --- a/.conda/recipe.yaml +++ b/.conda/recipe.yaml @@ -10,8 +10,6 @@ build: noarch: python script: - set PIP_NO_INDEX= -# - python -m pip install paho-mqtt opentrons_shared_data -# - python -m pip install git+https://github.com/Xuwznln/pylabrobot.git - if: win then: - copy %RECIPE_DIR%\..\MANIFEST.in %SRC_DIR% diff --git a/.conda/scripts/post-link.bat b/.conda/scripts/post-link.bat new file mode 100644 index 00000000..352b78ca --- /dev/null +++ b/.conda/scripts/post-link.bat @@ -0,0 +1,9 @@ +@echo off +setlocal enabledelayedexpansion + +REM upgrade pip +"%PREFIX%\python.exe" -m pip install --upgrade pip + +REM install extra deps +"%PREFIX%\python.exe" -m pip install paho-mqtt opentrons_shared_data +"%PREFIX%\python.exe" -m pip install git+https://github.com/Xuwznln/pylabrobot.git diff --git a/.conda/scripts/post-link.sh b/.conda/scripts/post-link.sh new file mode 100644 index 00000000..ef96f159 --- /dev/null +++ b/.conda/scripts/post-link.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash +set -euxo pipefail + +# make sure pip is available +"$PREFIX/bin/python" -m pip install --upgrade pip + +# install extra deps +"$PREFIX/bin/python" -m pip install paho-mqtt opentrons_shared_data +"$PREFIX/bin/python" -m pip install git+https://github.com/Xuwznln/pylabrobot.git diff --git a/.github/workflows/multi-platform-build.yml b/.github/workflows/multi-platform-build.yml index 7b703c7b..a8785da8 100644 --- a/.github/workflows/multi-platform-build.yml +++ b/.github/workflows/multi-platform-build.yml @@ -122,20 +122,10 @@ jobs: if-no-files-found: warn retention-days: 30 - - name: Login to Anaconda with API token - if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) - run: | - anaconda login --token ${{ secrets.ANACONDA_API_TOKEN }} - - name: Upload to Anaconda.org (unilab organization) - if: steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) + if: steps.should_build.outputs.should_build == 'true' && github.event.inputs.upload_to_anaconda == 'true' run: | for package in $(find ./output -name "*.conda"); do echo "Uploading $package to unilab organization..." - anaconda upload --user uni-lab --force "$package" + anaconda -t ${{ secrets.ANACONDA_API_TOKEN }} upload --user uni-lab --force "$package" done - - - name: Logout from Anaconda - if: always() && steps.should_build.outputs.should_build == 'true' && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) - run: | - anaconda logout || true diff --git a/.github/workflows/unilabos-conda-build.yml b/.github/workflows/unilabos-conda-build.yml index 9b5fbfb2..38b483a2 100644 --- a/.github/workflows/unilabos-conda-build.yml +++ b/.github/workflows/unilabos-conda-build.yml @@ -75,20 +75,10 @@ jobs: if-no-files-found: warn retention-days: 30 - - name: Login to Anaconda with API token - if: github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request') - run: | - anaconda login --token ${{ secrets.ANACONDA_API_TOKEN }} - - name: Upload to Anaconda.org (uni-lab organization) - if: github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request') + if: github.event.inputs.upload_to_anaconda == 'true' run: | for package in $(find ./output -name "*.conda"); do echo "Uploading $package to uni-lab organization..." - anaconda upload --user uni-lab --force "$package" + anaconda -t ${{ secrets.ANACONDA_API_TOKEN }} upload --user uni-lab --force "$package" done - - - name: Logout from Anaconda - if: always() && (github.event.inputs.upload_to_anaconda == 'true' || (github.ref == 'refs/heads/main' && github.event_name != 'pull_request')) - run: | - anaconda logout || true diff --git a/README.md b/README.md index 374632b3..142e7f9d 100644 --- a/README.md +++ b/README.md @@ -34,20 +34,14 @@ Detailed documentation can be found at: ## Quick Start -1. Configure Conda Environment - Uni-Lab-OS recommends using `mamba` for environment management. Choose the appropriate environment file for your operating system: ```bash # Create new environment -mamba create -n unilab unilab -c unilab -c robostack -c robostack-staging -c conda-forge - -# Or update existing environment -# Where `[YOUR_OS]` can be `win64`, `linux-64`, `osx-64`, or `osx-arm64`. -conda env update --file unilabos-[YOUR_OS].yml -n environment_name +mamba create -n unilab uni-lab::unilabos -c robostack-staging -c conda-forge ``` -2. Install Uni-Lab-OS: +## Install Dev Uni-Lab-OS ```bash # Clone the repository diff --git a/README_zh.md b/README_zh.md index 833c2d89..9ac81598 100644 --- a/README_zh.md +++ b/README_zh.md @@ -40,14 +40,10 @@ Uni-Lab-OS 建议使用 `mamba` 管理环境。根据您的操作系统选择适 ```bash # 创建新环境 -mamba create -n unilab unilab -c unilab -c robostack -c robostack-staging -c conda-forge - -# 或更新现有环境 -# 其中 `[YOUR_OS]` 可以是 `win64`, `linux-64`, `osx-64`, 或 `osx-arm64`。 -conda env update --file unilabos-[YOUR_OS].yml -n 环境名 +mamba create -n unilab uni-lab::unilabos -c robostack-staging -c conda-forge ``` -2. 安装 Uni-Lab-OS: +2. 安装开发版Uni-Lab-OS: ```bash # 克隆仓库