Unit test before release, move src/init to cli form
This commit is contained in:
parent
7d7aa8de33
commit
b52882ef2d
15 changed files with 956 additions and 3008 deletions
|
@ -6,7 +6,7 @@ on:
|
|||
- cron: "10 0 * * *" # Runs at 00:10 UTC every day
|
||||
|
||||
jobs:
|
||||
sync:
|
||||
release:
|
||||
name: Sync
|
||||
runs-on: docker
|
||||
container:
|
||||
|
@ -20,7 +20,13 @@ jobs:
|
|||
with:
|
||||
token: ${{ secrets.githubtoken }}
|
||||
|
||||
- name: Install fj
|
||||
- name: Install Luau
|
||||
uses: https://github.com/EncodedVenom/install-luau@v4
|
||||
with:
|
||||
version: "latest"
|
||||
verbose: "true"
|
||||
|
||||
- name: Install forgejo-cli
|
||||
run: |
|
||||
wget https://codeberg.org/Cyborus/forgejo-cli/releases/download/v0.2.0/forgejo-cli-linux.gz -O fj.gz
|
||||
gunzip fj.gz
|
||||
|
@ -36,8 +42,19 @@ jobs:
|
|||
wally login --token "${{ secrets.wally_auth_token }}"
|
||||
rm wally.toml
|
||||
|
||||
- name: Sync & Release
|
||||
run: lune run src/init
|
||||
- name: Synchronize
|
||||
run: lune run src/init -- sync jecs
|
||||
|
||||
- name: Run Unit Tests
|
||||
run: |
|
||||
output=$(lune run src/init -- test jecs)
|
||||
echo "$output"
|
||||
if [[ "$output" == *"0 fails"* ]]; then
|
||||
echo "Unit Tests Passed"
|
||||
else
|
||||
echo "Error: One or More Unit Tests Failed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
- name: Read Jecs Version
|
||||
id: read_jecs_version
|
||||
|
@ -45,6 +62,22 @@ jobs:
|
|||
version=$(lune run src/read_version | tr '\n' ' ')
|
||||
echo "JECS_VERSION=$version" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Build With Rojo
|
||||
run: |
|
||||
cd jecs
|
||||
rojo build default.project.json -o build.rbxm
|
||||
mv build.rbxm ../jecs_nightly.rbxm
|
||||
cd ..
|
||||
|
||||
- name: Upload Build Artifact
|
||||
uses: https://git.devmarked.win/actions/upload-artifact@v4
|
||||
with:
|
||||
name: build-${{ steps.read_jecs_version.outputs.JECS_VERSION }}
|
||||
path: jecs_nightly.rbxm
|
||||
|
||||
- name: Release
|
||||
run: lune run src/init -- release jecs --pesde-scope marked/jecs_nightly --wally-scope mark-marks/jecs-nightly
|
||||
|
||||
- name: Create Pull Request
|
||||
id: create_pull_request
|
||||
uses: https://git.devmarked.win/actions/create-pull-request@7174d368c2e4450dea17b297819eb28ae93ee645
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue