Skip to content

Add client_encoding to connection string (#741) #75

Add client_encoding to connection string (#741)

Add client_encoding to connection string (#741) #75

Workflow file for this run

# Copyright 2022 Open Reaction Database Project Authors
#
# 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: Publish
on:
push:
branches:
- main
jobs:
publish:
if: github.repository == 'open-reaction-database/ord-schema'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.ACTIONS_PUSH }}
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- uses: actions/setup-node@v3
with:
node-version: '16.x'
# https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
registry-url: 'https://registry.npmjs.org'
- name: Bump patch version
run: |
git config user.name github-actions
git config user.email github-actions@github.com
python -m pip install bump2version
bump2version patch --verbose
git push --tags origin main
- name: Create release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
# https://gist.github.com/rponte/fdc0724dd984088606b0?permalink_comment_id=3064455#gistcomment-3064455
gh release create "$(git tag | sort -V | tail -n 1)" --generate-notes
- name: Build and upload to PyPI
env:
TWINE_USERNAME: '__token__'
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade build twine wheel
python -m build
python -m twine upload dist/*
- name: Build and upload to NPM
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
cd js/ord-schema
npm install
npm run build
npm publish