Skip to content

use requirements.txt #2

use requirements.txt

use requirements.txt #2

name: Build and Deploy to GitHub Pages
on:
push:
branches: [ "master", "main" ]
pull_request:
branches: [ "master", "main" ]
workflow_dispatch:
jobs:
build:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Get Data
uses: actions/checkout@v3
with:
repository: "LeStegii/server-softwares"
path: "."
ref: "master"
- name: Get Frontend
uses: actions/checkout@v3
with:
repository: "lunofe/mcss-frontend"
path: "mcss-frontend"
ref: "main"
- name: Set up Python 3.11
uses: actions/setup-python@v3
with:
python-version: "3.11"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r mcss-frontend/requirements.txt
- name: Run Python Build Script
run: |
cd mcss-frontend
git log -1 --pretty=%h > commit.txt
cd ..
python3 mcss-frontend/build.py
- name: Deploy to GitHub Pages
uses: JamesIves/github-pages-deploy-action@4.1.0
with:
branch: website
folder: mcss-frontend/build