File tree Expand file tree Collapse file tree 2 files changed +55
-1
lines changed Expand file tree Collapse file tree 2 files changed +55
-1
lines changed Original file line number Diff line number Diff line change 1+ name : Generate Thrift Code
2+
3+ on :
4+ push :
5+ branches :
6+ - github_action_test
7+ pull_request :
8+ branches :
9+ - github_action_test
10+
11+ jobs :
12+ generate :
13+ runs-on : ubuntu-latest
14+
15+ steps :
16+ - name : Checkout code
17+ uses : actions/checkout@v3
18+ with :
19+ token : ${{ secrets.GITHUB_TOKEN }}
20+
21+ - name : Set up Python
22+ uses : actions/setup-python@v4
23+ with :
24+ python-version : ' 3.x'
25+
26+ - name : Install Thrift
27+ run : |
28+ sudo apt-get install -y thrift-compiler
29+ python3 -m pip install --upgrade pip
30+ pip install -r requirements.txt
31+
32+ - name : Run generate.sh
33+ run : |
34+ chmod +x ./generate.sh
35+ ./generate.sh
36+
37+ - name : Check for changes
38+ run : |
39+ git config --global user.name "github-actions[bot]"
40+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
41+ git add soccer/*
42+ if ! git diff --cached --quiet; then
43+ git commit -m "Automated update: Generated Thrift classes"
44+ else
45+ echo "No changes detected, skipping commit."
46+ fi
47+
48+ - name : Push changes
49+ if : github.event_name == 'push' && github.ref == 'refs/heads/github_action_test'
50+ run : |
51+ git push origin github_action_test
52+ env :
53+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change @@ -6,7 +6,8 @@ namespace py soccer
66enum ViewWidth {
77 NARROW = 0 ,
88 NORMAL = 1 ,
9- WIDE = 2
9+ WIDE = 2 ,
10+ test = 3
1011}
1112
1213enum AgentType {
You can’t perform that action at this time.
0 commit comments