bogus change #30
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: bmark_M1 | |
on: | |
pull_request_target: | |
types: | |
- labeled | |
jobs: | |
bmark: | |
name: Julia ${{ matrix.version }} - macOS - ${{ matrix.arch }} - ${{ github.event_name }} | |
if: contains(github.event.pull_request.labels.*.name, 'benchmarks') | |
runs-on: [self-hosted, macOS] | |
strategy: | |
fail-fast: false | |
matrix: | |
version: | |
- 1 | |
arch: | |
- aarch64 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: julia-actions/setup-julia@v1 | |
with: | |
version: ${{ matrix.version }} | |
arch: ${{ matrix.arch }} | |
- uses: julia-actions/julia-buildpkg@v1 | |
- name: Installing non-registered dependencies | |
run: | | |
using Pkg | |
pkg1 = PackageSpec(url = "https://github.com/JuliaSmoothOptimizers/JSOBenchmarks.jl.git", rev = "main") | |
pkg_list = [pkg1] | |
Pkg.add(pkg_list) | |
shell: julia --project=benchmark --color=yes {0} | |
- name: Install benchmark dependencies | |
run: julia --project=benchmark -e 'using Pkg; Pkg.instantiate()' | |
- name: Run benchmarks | |
run: julia --project=benchmark -e 'using JSOBenchmarks; run_benchmarks(${{ github.event.repository.name }}, "benchmark", reference_branch = "bmark-workflow")' | |
env: | |
GITHUB_AUTH: ${{ secrets.GIST_TOKEN }} | |
# - name: Post benchmark results in PR | |
# uses: thollander/actions-comment-pull-request@v2 | |
# with: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# message: "Full benchmark results stored as artifacts. Summary: ${{ secrets.BMARK_GIST_URL }}" | |
- name: Build comment | |
id: build-comment | |
uses: actions/github-script@v6 | |
with: | |
github-token: ${{ github.token }} | |
result-encoding: string | |
script: | | |
const fs = require('fs'); | |
return "<details>\n<summary>Benchmark Summary</summary>\n\n```\n" + fs.readFileSync("${{ github.workspace }}/${{ github.sha }}.md", "utf8").toString() + "\n```\n</details>"; | |
- name: Comment in PR | |
uses: thollander/actions-comment-pull-request@v2 | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
message: ${{ steps.build-comment.outputs.result }} | |
- name: Upload benchmark plots | |
uses: edunad/[email protected] | |
with: | |
path: './*.png' | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
title: 'Benchmarks at a Glance' | |
annotationLevel: 'notice' | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v2 | |
with: | |
name: benchmarks | |
path: | | |
profiles_commit_vs_main_*.svg | |
*_vs_main_*.jld2 | |
main.md | |
${{ github.sha }}.md | |
judgement_${{ github.sha }}.md |