Skip to content

Develop #16

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Nov 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions .github/workflows/grpc-generate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Generate gRPC Code

on:
push:
branches:
- main

jobs:
generate:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'

- name: Install gRPC tools
run: |
python3 -m pip install --upgrade pip
pip install -r requirements.txt

- name: Run generate.sh
run: |
chmod +x ./generate.sh
./generate.sh
- name: Check for changes
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git add .
if ! git diff --cached --quiet; then
git commit -m "Automated update: Generated Thrift classes"
else
echo "No changes detected, skipping commit."
fi
- name: Push changes
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
git push origin main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7 changes: 2 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,5 @@
scripts/proxy
scripts/rcssserver
logs/
__pycache__/check_requirements.cpython-310.pyc
__pycache__/service_pb2_grpc.cpython-310.pyc
__pycache__/service_pb2.cpython-310.pyc
utils/__pycache__/__init__.cpython-310.pyc
utils/__pycache__/logger_utils.cpython-310.pyc
__pycache__/
utils/__pycache__/
Loading