Skip to content

armgit / cua

Public Imported from GitHub
0

Scale computer-use 2.0 with open-source drivers, cross-OS sandboxes, and benchmarks for training, evaluation, and data generation.

Delete .github/workflows/publish-all.yml

f-trycua9baab6f00a66
diff --git a/.github/workflows/publish-all.yml b/.github/workflows/publish-all.yml
deleted file mode 100644
index f7e7e405f5..0000000000
--- a/.github/workflows/publish-all.yml
+++ /dev/null
@@ -1,227 +0,0 @@
-name: Publish All Packages
-
-on:
- push:
- tags:
- - 'v*' # For global releases (vX.Y.Z format)
- workflow_dispatch:
- inputs:
- version:
- description: 'Version to publish (without v prefix)'
- required: true
- default: '0.1.0'
- packages:
- description: 'Packages to publish (comma-separated)'
- required: false
- default: 'core,pylume,computer,som,agent,computer-server'
-
-# Adding permissions at workflow level
-permissions:
- contents: write
-
-jobs:
- setup:
- runs-on: macos-latest
- outputs:
- version: ${{ steps.get-version.outputs.version }}
- publish_core: ${{ steps.set-packages.outputs.publish_core }}
- publish_pylume: ${{ steps.set-packages.outputs.publish_pylume }}
- publish_computer: ${{ steps.set-packages.outputs.publish_computer }}
- publish_som: ${{ steps.set-packages.outputs.publish_som }}
- publish_agent: ${{ steps.set-packages.outputs.publish_agent }}
- publish_computer_server: ${{ steps.set-packages.outputs.publish_computer_server }}
- steps:
- - name: Determine version
- id: get-version
- run: |
- if [ "${{ github.event_name }}" == "push" ]; then
- # Extract version from tag (for global releases)
- if [[ "${{ github.ref }}" =~ ^refs/tags/v([0-9]+\.[0-9]+\.[0-9]+) ]]; then
- VERSION=${BASH_REMATCH[1]}
- else
- echo "Invalid tag format for global release"
- exit 1
- fi
- else
- # Use version from workflow dispatch
- VERSION=${{ github.event.inputs.version }}
- fi
- echo "version=$VERSION" >> $GITHUB_OUTPUT
- echo "Using version: $VERSION"
-
- - name: Determine packages to publish
- id: set-packages
- run: |
- # Default to all packages for tag-based releases
- if [ "${{ github.event_name }}" == "push" ]; then
- PACKAGES="core,pylume,computer,som,agent,computer-server"
- else
- # Use packages from workflow dispatch
- PACKAGES="${{ github.event.inputs.packages }}"
- fi
-
- # Set individual flags for each package
- echo "publish_core=$(echo $PACKAGES | grep -q "core" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
- echo "publish_pylume=$(echo $PACKAGES | grep -q "pylume" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
- echo "publish_computer=$(echo $PACKAGES | grep -q "computer" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
- echo "publish_som=$(echo $PACKAGES | grep -q "som" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
- echo "publish_agent=$(echo $PACKAGES | grep -q "agent" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
- echo "publish_computer_server=$(echo $PACKAGES | grep -q "computer-server" && echo "true" || echo "false")" >> $GITHUB_OUTPUT
-
- echo "Publishing packages: $PACKAGES"
-
- publish-core:
- needs: setup
- if: ${{ needs.setup.outputs.publish_core == 'true' }}
- uses: ./.github/workflows/publish-core.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- # Add a delay to ensure PyPI has registered the new core version
- wait-for-core:
- needs: [setup, publish-core]
- if: ${{ needs.setup.outputs.publish_core == 'true' && (needs.setup.outputs.publish_computer == 'true' || needs.setup.outputs.publish_agent == 'true') }}
- runs-on: macos-latest
- steps:
- - name: Wait for PyPI to update
- run: |
- echo "Waiting for PyPI to register the new core version..."
- sleep 60 # Wait 60 seconds for PyPI to update its index
-
- publish-pylume:
- needs: setup
- if: ${{ needs.setup.outputs.publish_pylume == 'true' }}
- uses: ./.github/workflows/publish-pylume.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- # Add a delay to ensure PyPI has registered the new pylume version
- wait-for-pylume:
- needs: [setup, publish-pylume]
- if: ${{ needs.setup.outputs.publish_pylume == 'true' && (needs.setup.outputs.publish_computer == 'true' || needs.setup.outputs.publish_som == 'true') }}
- runs-on: macos-latest
- steps:
- - name: Wait for PyPI to update
- run: |
- echo "Waiting for PyPI to register the new pylume version..."
- sleep 60 # Wait 60 seconds for PyPI to update its index
-
- publish-computer:
- needs: [setup, publish-core, publish-pylume, wait-for-core, wait-for-pylume]
- if: ${{ needs.setup.outputs.publish_computer == 'true' }}
- uses: ./.github/workflows/publish-computer.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- publish-som:
- needs: [setup, publish-pylume, wait-for-pylume]
- if: ${{ needs.setup.outputs.publish_som == 'true' }}
- uses: ./.github/workflows/publish-som.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- # Add a delay to ensure PyPI has registered the new computer and som versions
- wait-for-deps:
- needs: [setup, publish-computer, publish-som]
- if: ${{ (needs.setup.outputs.publish_computer == 'true' || needs.setup.outputs.publish_som == 'true') && needs.setup.outputs.publish_agent == 'true' }}
- runs-on: macos-latest
- steps:
- - name: Wait for PyPI to update
- run: |
- echo "Waiting for PyPI to register new dependency versions..."
- sleep 60 # Wait 60 seconds for PyPI to update its index
-
- publish-agent:
- needs: [setup, publish-core, publish-computer, publish-som, wait-for-core, wait-for-deps]
- if: ${{ needs.setup.outputs.publish_agent == 'true' }}
- uses: ./.github/workflows/publish-agent.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- publish-computer-server:
- needs: [setup, publish-computer]
- if: ${{ needs.setup.outputs.publish_computer_server == 'true' }}
- uses: ./.github/workflows/publish-computer-server.yml
- with:
- version: ${{ needs.setup.outputs.version }}
- secrets: inherit
-
- # Create a global release for the entire CUA project
- create-global-release:
- needs: [setup, publish-core, publish-pylume, publish-computer, publish-som, publish-agent, publish-computer-server]
- if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') }}
- runs-on: macos-latest
- steps:
- - uses: actions/checkout@v4
-
- - name: Create Summary Release Notes
- id: release_notes
- run: |
- VERSION=${{ needs.setup.outputs.version }}
-
- # Create the release notes file
- echo "# CUA v${VERSION} Release" > release_notes.md
- echo "" >> release_notes.md
- echo "This is a global release of the Computer Universal Automation (CUA) project." >> release_notes.md
- echo "" >> release_notes.md
-
- echo "## Released Packages" >> release_notes.md
- echo "" >> release_notes.md
-
- # Add links to individual package releases
- if [[ "${{ needs.setup.outputs.publish_core }}" == "true" ]]; then
- echo "- [cua-core v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/core-v${VERSION})" >> release_notes.md
- fi
-
- if [[ "${{ needs.setup.outputs.publish_pylume }}" == "true" ]]; then
- echo "- [pylume v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/pylume-v${VERSION})" >> release_notes.md
- fi
-
- if [[ "${{ needs.setup.outputs.publish_computer }}" == "true" ]]; then
- echo "- [cua-computer v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/computer-v${VERSION})" >> release_notes.md
- fi
-
- if [[ "${{ needs.setup.outputs.publish_som }}" == "true" ]]; then
- echo "- [cua-som v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/som-v${VERSION})" >> release_notes.md
- fi
-
- if [[ "${{ needs.setup.outputs.publish_agent }}" == "true" ]]; then
- echo "- [cua-agent v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/agent-v${VERSION})" >> release_notes.md
- fi
-
- if [[ "${{ needs.setup.outputs.publish_computer_server }}" == "true" ]]; then
- echo "- [cua-computer-server v${VERSION}](https://github.com/${{ github.repository }}/releases/tag/computer-server-v${VERSION})" >> release_notes.md
- fi
-
- echo "" >> release_notes.md
- echo "## Installation" >> release_notes.md
- echo "" >> release_notes.md
- echo "### Core Libraries" >> release_notes.md
- echo "```bash" >> release_notes.md
- echo "pip install cua-core==${VERSION}" >> release_notes.md
- echo "pip install cua-computer==${VERSION}" >> release_notes.md
- echo "pip install pylume==${VERSION}" >> release_notes.md
- echo "```" >> release_notes.md
- echo "" >> release_notes.md
- echo "### Agent with SOM (Recommended)" >> release_notes.md
- echo "```bash" >> release_notes.md
- echo "pip install cua-agent[som]==${VERSION}" >> release_notes.md
- echo "```" >> release_notes.md
-
- echo "Release notes created:"
- cat release_notes.md
-
- - name: Create GitHub Global Release
- uses: softprops/action-gh-release@v1
- with:
- name: "CUA v${{ needs.setup.outputs.version }}"
- body_path: release_notes.md
- draft: false
- prerelease: false
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
\ No newline at end of file