Skip to content

Remove codepage dependency as we are vendoring it. #19

Remove codepage dependency as we are vendoring it.

Remove codepage dependency as we are vendoring it. #19

Workflow file for this run

name: Build
on:
push:
branches:
- master
- stable
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up Node.js
uses: actions/[email protected]
with:
node-version: '21'
- name: Set up Java
uses: actions/[email protected]
with:
java-version: '21'
distribution: 'temurin'
- name: Get next version
uses: reecetech/[email protected]
id: version
with:
scheme: semver
release_branch: stable
increment: patch
- name: Tag Commit
if: github.ref == 'refs/heads/stable'
uses: CrabMatrix/[email protected]
with:
tag: ${{ steps.version.outputs.version }}
repo-token: "${{ secrets.GITHUB_TOKEN }}"
- name: Build package
run: |
echo "Building package"
make pkg
- name: Update package version
run: |
echo "Updating package version to ${{ steps.version.outputs.version }}"
sed -i "s/\"version\": \".*\"/\"version\": \"${{ steps.version.outputs.version }}\"/" temp_files/sabre/package.json
- name: Publish package
run: |
echo "Publishing package"
pushd temp_files/sabre && npm config set _authToken=$NODE_AUTH_TOKEN && npm config fix && npm publish && popd
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
- name: Create release
if: github.ref == 'refs/heads/stable'
id: create_release
uses: release-drafter/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
config-file: .github/release-drafter.yml
tag: ${{ steps.version.outputs.version }}
name: ${{ steps.version.outputs.version }}
version: ${{ steps.version.outputs.version }}
- name: Zip Release
if: github.ref == 'refs/heads/stable'
run: zip -r -9 SABRE,js-${{ steps.version.outputs.version }}.zip ./bin ./debugbin ./LICENSE.md
- name: Upload Release
if: github.ref == 'refs/heads/stable'
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./SABRE,js-${{ steps.version.outputs.version }}.zip
asset_name: SABRE,js-${{ steps.version.outputs.version }}.zip
asset_content_type: application/zip
- name: Publish Release
if: github.ref == 'refs/heads/stable'
uses: eregon/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
release_id: ${{ steps.create_release.outputs.id }}