diff --git a/.gitea/workflows/python-test.yml b/.gitea/workflows/python-test.yml new file mode 100644 index 0000000..2ccdf5b --- /dev/null +++ b/.gitea/workflows/python-test.yml @@ -0,0 +1,24 @@ +name: Python Test +on: [push] + +jobs: + python-hello: + runs-on: [ubuntu-latest] + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Install Python 3 if missing + run: | + if ! command -v python3 >/dev/null; then + sudo apt-get update + sudo apt-get install -y python3 python3-venv python3-pip + fi + + - name: Verify Python installation + run: python3 --version + + - name: Run “Hello, Python!” + run: | + echo 'print("Hello, Python!")' > main.py + python3 main.py \ No newline at end of file