Files
OpenLLM/.github/workflows/release-notes.yml
aarnphm-ec2-dev d37d14e52b fix(tests): mark package on CI to xfail
XXX: @aarnphm to solve build isolation when have bandwidth. Currently
this is not a problem when running locally.

`openllm build` just works, where as `openllm.build` won't work
sequentially.

Address some type stubs for jupytext

Signed-off-by: aarnphm-ec2-dev <29749331+aarnphm@users.noreply.github.com>
2023-07-15 12:48:28 +00:00

122 lines
4.0 KiB
YAML

# Copyright 2023 BentoML Team. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: release-notes
on:
workflow_dispatch:
inputs:
tags:
description: 'Tag for releases'
required: true
type: string
workflow_call:
inputs:
tags:
required: true
type: string
env:
HATCH_VERBOSE: 2
defaults:
run:
shell: bash --noprofile --norc -exo pipefail {0}
jobs:
gen-release-notes:
if: github.repository_owner == 'bentoml'
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
ref: 'v${{ inputs.tags }}'
- name: Setup CI
uses: ./.github/actions/setup-repo
with:
python-version: '3.11'
- name: Create release notes
run: ./.github/actions/create_release_and_archive.sh ${{ inputs.tags }}
- name: Download Python artifacts
uses: actions/download-artifact@v3
with:
name: python-artifacts
path: dist
- name: Download binaries
uses: actions/download-artifact@v3
with:
name: standalone
path: archives
- name: Download installers
uses: actions/download-artifact@v3
with:
name: installers
path: installers
- name: Create release
uses: softprops/action-gh-release@v1
with:
# Use GH feature to populate the changelog automatically
generate_release_notes: true
body_path: release_notes.txt
fail_on_unmatched_files: true
tag_name: 'v${{ inputs.tags }}'
files: |-
dist/*
archives/*
installers/*
bump-dev:
if: github.repository_owner == 'bentoml'
needs: [gen-release-notes]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup CI
uses: ./.github/actions/setup-repo
with:
python-version: '3.11'
- name: Import bot's GPG key for signing commits
id: import-gpg
uses: crazy-max/ghaction-import-gpg@v5
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
git_config_global: true
git_user_signingkey: true
git_commit_gpgsign: true
git_tag_gpgsign: true
git_push_gpgsign: true
- name: Install jq and curl
run: sudo apt-get install -y jq curl
- name: Bump version to dev
env:
GIT_AUTHOR_NAME: ${{ steps.import-gpg.outputs.name }}
GIT_AUTHOR_EMAIL: ${{ steps.import-gpg.outputs.email }}
GIT_COMMITTER_NAME: ${{ steps.import-gpg.outputs.name }}
GIT_COMMITTER_EMAIL: ${{ steps.import-gpg.outputs.email }}
run: |
git config --global user.name "${{ steps.import-gpg.outputs.name }}"
git config --global user.email "${{ steps.import-gpg.outputs.email }}"
git pull --autostash --no-edit --gpg-sign --ff origin main
echo "Bumping version to dev..." && hatch version patch && hatch version dev
jq --arg release_version "$(hatch version)" '.version = $release_version' < package.json > package.json.tmp && mv package.json.tmp package.json
git add src/openllm/__about__.py package.json && git commit -S -sm "infra: bump to dev version of $(hatch version) [generated]"
git push origin HEAD:main