Skip to content

Commit

Permalink
Merge pull request #1328 from Sage-Bionetworks/develop-revert-workflo…
Browse files Browse the repository at this point in the history
…w-changes

Revert changes related to workflow
  • Loading branch information
linglp authored Dec 12, 2023
2 parents bf4e10d + b0788c7 commit c66d799
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 25 deletions.
41 changes: 19 additions & 22 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
name: Publish to PyPI
on:
push:
branches: [develop-refactor-schemas]
# on:
# push:
# tags:
# - 'v[1-9][0-9].[0-9]+.[0-9]+'
# branches: [main]
tags:
- 'v[1-9][0-9].[0-9]+.[0-9]+'
branches: [main]

jobs:
pypi_release:
runs-on: ubuntu-latest
env:
POETRY_VERSION: 1.3.0
# if: github.event_name == 'push' && contains(github.ref, 'refs/tags')
if: github.event_name == 'push' && contains(github.ref, 'refs/tags')
steps:
#----------------------------------------------
# check-out repo and set-up python
Expand Down Expand Up @@ -99,7 +96,7 @@ jobs:
#----------------------------------------------
- name: Publish package to Pypi
id: publish-to-pypi
# if: steps.check-tag.outputs.match == 'true'
if: steps.check-tag.outputs.match == 'true'
env:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
PYPI_USERNAME: __token__
Expand All @@ -110,17 +107,17 @@ jobs:
# post a message to slack
#----------------------------------------------

# - name: Post to a Slack channel
# if: steps.publish-to-pypi.outcome == 'success'
# id: slack
# uses: slackapi/[email protected]
# with:
# # Slack channel id, channel name, or user id to post message.
# # See also: https://api.slack.com/methods/chat.postMessage#channels
# # You can pass in multiple channels to post to by providing a comma-delimited list of channel IDs.
# # ibc-fair-data channel and data-curator-schematic channel
# channel-id: 'C050YD75QRL,C01ANC02U59'
# # For posting a simple plain text message
# slack-message: "Schematic has just been released. Check out new version: ${{ github.ref_name }}"
# env:
# SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
- name: Post to a Slack channel
if: steps.publish-to-pypi.outcome == 'success'
id: slack
uses: slackapi/[email protected]
with:
# Slack channel id, channel name, or user id to post message.
# See also: https://api.slack.com/methods/chat.postMessage#channels
# You can pass in multiple channels to post to by providing a comma-delimited list of channel IDs.
# ibc-fair-data channel and data-curator-schematic channel
channel-id: 'C050YD75QRL,C01ANC02U59'
# For posting a simple plain text message
slack-message: "Schematic has just been released. Check out new version: ${{ github.ref_name }}"
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
4 changes: 1 addition & 3 deletions override_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@

data = toml.load("pyproject.toml")
#get release version
# RELEASE_VERSION = os.getenv('RELEASE_VERSION')
# temporarily hard coded release version
RELEASE_VERSION = 'v23.11.dev2'
RELEASE_VERSION = os.getenv('RELEASE_VERSION')
# Modify field
data['tool']['poetry']['version']=RELEASE_VERSION
print('the version number of this release is: ', RELEASE_VERSION)
Expand Down

0 comments on commit c66d799

Please sign in to comment.