Skip to content

Commit e6b6385

Browse files
committed
WIP linearization workflow testing.
Change-Id: I3c52cf289ab06fa38a2ad24984286115202f481d
1 parent 4b8f93f commit e6b6385

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: linearize_main
2+
3+
on:
4+
schedule:
5+
# GMT timezone.
6+
- cron: '0 10 * * *'
7+
workflow_dispatch:
8+
9+
permissions: read-all
10+
11+
jobs:
12+
trigger_linearize:
13+
runs-on: ubuntu-latest
14+
permissions:
15+
contents: write
16+
steps:
17+
- name: Checkout main
18+
uses: actions/checkout@v4
19+
with:
20+
ref: main
21+
- name: Checkout rebase_tools
22+
uses: actions/checkout@v4
23+
with:
24+
ref: experimental/rebase_tools
25+
- uses: actions/setup-python@v5
26+
with:
27+
python-version: '3.9'
28+
cache: 'pip'
29+
- name: Install rebase_tools
30+
run: |
31+
set -eux
32+
pip install -r requirements.txt
33+
- name: Run linearize
34+
run: |
35+
set -eux
36+
# m114 merge commit=38a06fe8674ad2140ff85c87b5b3a817304e369a
37+
export REV=$(git rev-parse main)
38+
echo $REV
39+
python main.py linearize --repo-path=${GITHUB_WORKSPACE} --source-branch=main --new-branch-name=feature/linear_main \
40+
--start-commit-ref=38a06fe8674ad2140ff85c87b5b3a817304e369a --end-commit-ref=${REV}
41+
- name: Checkout feature/linear_main
42+
uses: actions/checkout@v4
43+
with:
44+
ref: feature/rebase_tools
45+
# - name: Push to origin feature/linear_main
46+
# run: |
47+
# set -eux
48+
# git push --force origin feature/linear_main
49+

0 commit comments

Comments
 (0)