|
19 | 19 | GH_PAGES_BRANCH: benchmark-pages |
20 | 20 |
|
21 | 21 | steps: |
22 | | - - uses: actions/checkout@v2 |
| 22 | + - uses: actions/checkout@v5 |
23 | 23 |
|
24 | | - - uses: cachix/install-nix-action@v15 |
| 24 | + - uses: cachix/install-nix-action@v31 |
25 | 25 | with: |
26 | 26 | nix_path: nixpkgs=channel:nixos-unstable |
27 | 27 | extra_nix_config: | |
|
41 | 41 | nix-env -i jq -f '<nixpkgs>' |
42 | 42 | jq -f .github/tools/extract_criterion.jq < libs/cardano-ledger-test/bench.json > output.json |
43 | 43 |
|
44 | | - - name: Truncate benchmark git history |
45 | | - run: | |
46 | | - git fetch origin refs/heads/$GH_PAGES_BRANCH:refs/remotes/origin/$GH_PAGES_BRANCH |
47 | | - git checkout -t origin/$GH_PAGES_BRANCH |
48 | | - START=$(git rev-parse "@{2 weeks ago}") |
49 | | - git checkout --orphan new-root $START |
50 | | - git config user.name "$(git log -1 --format=%cn $START)" |
51 | | - git config user.email "$(git log -1 --format=%ce $START)" |
52 | | - git commit -C $START |
53 | | - git rebase --onto new-root $START $GH_PAGES_BRANCH |
54 | | - git push -f |
55 | | - git checkout --detach |
56 | | -
|
57 | 44 | - name: Store benchmark results |
58 | 45 | uses: benchmark-action/github-action-benchmark@v1 |
59 | 46 | with: |
|
68 | 55 | comment-on-alert: true |
69 | 56 | fail-on-alert: true |
70 | 57 | alert-comment-cc-users: '@lehins' |
| 58 | + |
| 59 | + - name: Abbreviate git history |
| 60 | + run: | |
| 61 | + git branch -D $GH_PAGES_BRANCH || true |
| 62 | + git fetch origin refs/heads/$GH_PAGES_BRANCH*:refs/remotes/origin/$GH_PAGES_BRANCH* |
| 63 | + git checkout -t origin/$GH_PAGES_BRANCH |
| 64 | + git config user.name "$(git log -1 --format=%cn)" |
| 65 | + git config user.email "$(git log -1 --format=%ce)" |
| 66 | + git reset --keep origin/$GH_PAGES_BRANCH-base |
| 67 | + git checkout @{u} . |
| 68 | + git commit -C @{u} |
| 69 | + git push -f |
0 commit comments