File tree Expand file tree Collapse file tree 1 file changed +6
-16
lines changed Expand file tree Collapse file tree 1 file changed +6
-16
lines changed Original file line number Diff line number Diff line change 3
3
schedule :
4
4
- cron : ' 0 0 * * *' # Daily sync
5
5
workflow_dispatch : # Manual trigger
6
+
6
7
jobs :
7
8
sync :
8
9
runs-on : ubuntu-latest
9
- permissions :
10
- contents : write # Add explicit permission to write to repository contents
11
10
steps :
12
11
- name : Checkout
13
12
uses : actions/checkout@v4
14
13
with :
15
- fetch-depth : 0 # Fetch all history for proper merging
16
- token : ${{ secrets.GITHUB_TOKEN }} # Use the GitHub token with appropriate permissions
14
+ token : ${{ secrets.PAT_TOKEN }} # Required for push access
15
+ fetch-depth : 0
16
+
17
17
- name : Sync upstream
18
18
run : |
19
19
git config user.name "StrandForge Bot"
20
20
git config user.email "bot@strandforge.ai"
21
21
git remote add upstream https://github.com/strands-agents/sdk-python.git
22
22
git fetch upstream
23
23
git checkout base-main
24
-
25
- # Try normal merge first
26
- if ! git merge upstream/main --no-edit; then
27
- # If normal merge fails, try with allow-unrelated-histories
28
- echo "Normal merge failed, attempting with --allow-unrelated-histories"
29
- git merge upstream/main --allow-unrelated-histories --no-edit || {
30
- echo "Merge failed. There might be conflicts that need manual resolution."
31
- exit 1
32
- }
33
- fi
34
-
35
- git push origin base-main
24
+ git merge upstream/main --no-edit
25
+ git push origin base-main
You can’t perform that action at this time.
0 commit comments