From c788d771d3c19fc0b3127a082e25accaf3b208d1 Mon Sep 17 00:00:00 2001 From: Saket Aryan Date: Wed, 1 Apr 2026 21:29:10 +0530 Subject: [PATCH] feat(cli): add CD workflow and bump version to 0.2.0b1 (#4653) --- .github/workflows/cli-python-cd.yml | 34 +++++++++++++++++++++++++++++ cli/python/README.md | 7 ++++++ cli/python/pyproject.toml | 2 +- 3 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/cli-python-cd.yml diff --git a/.github/workflows/cli-python-cd.yml b/.github/workflows/cli-python-cd.yml new file mode 100644 index 000000000..316bc1df2 --- /dev/null +++ b/.github/workflows/cli-python-cd.yml @@ -0,0 +1,34 @@ +name: Publish mem0-cli 🐍 distributions 📦 to PyPI + +on: + release: + types: [published] + +jobs: + build-n-publish: + name: Build and publish mem0-cli 📦 to PyPI + if: startsWith(github.event.release.tag_name, 'cli-v') + runs-on: ubuntu-latest + permissions: + id-token: write + defaults: + run: + working-directory: cli/python + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.11' + + - name: Install Hatch + run: pip install hatch + + - name: Build a binary wheel and a source tarball + run: hatch build --clean + + - name: Publish distribution 📦 to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: cli/python/dist/ diff --git a/cli/python/README.md b/cli/python/README.md index 574004c30..f5fda837f 100644 --- a/cli/python/README.md +++ b/cli/python/README.md @@ -34,6 +34,13 @@ mem0 search "What are Alice's preferences?" --user-id alice mem0 list --user-id alice ``` +## Releasing + +1. Update `version` in `pyproject.toml` +2. Create a GitHub Release with tag `cli-v` (e.g. `cli-v0.2.0`) + +For a pre-release, use a beta version like `0.2.0b1` and check the **pre-release** checkbox. + ## License Apache-2.0 diff --git a/cli/python/pyproject.toml b/cli/python/pyproject.toml index 1c2b0fd8d..4c7200b5e 100644 --- a/cli/python/pyproject.toml +++ b/cli/python/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "mem0-cli" -version = "0.1.0" +version = "0.2.0b1" description = "The official CLI for mem0 — the memory layer for AI agents" readme = "README.md" license = "Apache-2.0"