Skip to content

increment benchmark #200

increment benchmark

increment benchmark #200

Workflow file for this run

# This file was automatically generated by sbt-github-actions using the
# githubWorkflowGenerate task. You should add and commit this file to
# your git repository. It goes without saying that you shouldn't edit
# this file by hand! Instead, if you wish to make changes, you should
# change your sbt build configuration to revise the workflow description
# to meet your needs, then regenerate this file.
name: Continuous Integration
on:
pull_request:
branches: ['**', '!update/**', '!pr/**']
push:
branches: ['**', '!update/**', '!pr/**', '!benchmark']
tags: [v*]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
concurrency:
group: ${{ github.workflow }} @ ${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build and Test
strategy:
matrix:
os: [ubuntu-latest]
scala: [3]
java: [temurin@17]
project: [js, jvm, native]
runs-on: ${{ matrix.os }}
timeout-minutes: 60
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: coursier/setup-action@main
with:
jvm: temurin@17
apps: mill scala-cli
- name: Setup NodeJS v18 LTS
if: matrix.project == 'js'
uses: actions/setup-node@v3
with:
node-version: 18
cache: npm
- name: formatCheck
run: mill mill.scalalib.scalafmt.ScalafmtModule/checkFormatAll __.sources
- if: matrix.project == 'js'
run: npm install
- if: matrix.project == 'native'
run: sudo apt-get install -y libatlas-base-dev
- name: scalaJSLink
if: matrix.project == 'js'
run: mill vecxt.${{ matrix.project }}.fastLinkJS
- name: nativeLink
if: matrix.project == 'native'
run: mill vecxt.${{ matrix.project }}.test.nativeLink
- name: Test
run: mill vecxt.${{ matrix.project }}.test
publish:
if: github.repository == 'Quafadas/vecxt' && contains(github.ref, 'refs/tags/')
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- uses: coursier/setup-action@main
with:
jvm: temurin@17
apps: mill scala-cli
- name: Setup GPG secrets
run: |
gpg --version
cat <(echo "${{ secrets.PGP_SECRET }}") | base64 --decode | gpg --batch --import
gpg --list-secret-keys --keyid-format LONG
- name: Publish to Maven Central
run: mill -i mill.scalalib.PublishModule/publishAll __.publishArtifacts --sonatypeUri https://s01.oss.sonatype.org/service/local --sonatypeCreds "${{ secrets.SONATYPE_USERNAME }}:${{ secrets.SONATYPE_PASSWORD }}" --gpgArgs "--passphrase=${{ secrets.PGP_PASSPHRASE}},--batch,--yes,-a,-b,--pinentry-mode,loopback" --readTimeout 1200000 --awaitTimeout 1200000 --release true --signed true
site:
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
needs: build
runs-on: ubuntu-latest
steps:
- uses: coursier/setup-action@main
with:
jvm: temurin@17
apps: mill scala-cli
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
ref: benchmark
- name: Aggregate benchmark results
run: |
chmod +x aggregate.sh
./aggregate.sh
- name: Switch to main branch
run: |
git fetch origin main
git checkout -f main
git reset --hard origin/main
ls
- name: Copy benchmark results into docs generation
run: mkdir -p site/docs/_assets/benchmarks && cp benchmark_history.json site/docs/_assets/benchmarks/benchmark_history.json
- name: Generate static site
run: mill site.publishDocs
- name: Setup Pages
uses: actions/configure-pages@v4
- uses: actions/upload-artifact@v3
with:
name: page
path: out/site/publishDocs.dest
if-no-files-found: error
deploy:
needs: site
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
with:
name: page
path: .
- uses: actions/configure-pages@v4
- uses: actions/upload-pages-artifact@v2
with:
path: .
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v3