Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

Commit

Permalink
v1.2.0 (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
cxmeel authored Apr 7, 2022
1 parent 0750ae5 commit a9ce295
Show file tree
Hide file tree
Showing 91 changed files with 2,204 additions and 1,565 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Deploy Docs

on:
push:
branches:
- default

jobs:
deploy:
name: Build and Deploy Docs
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Setup Node LTS
uses: actions/setup-node@v2
with:
node-version: lts

- name: Install Moonwave
run: npm install -g moonwave

- name: Publish Docs
run: moonwave build --publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
56 changes: 0 additions & 56 deletions .github/workflows/publish-release.yml

This file was deleted.

79 changes: 0 additions & 79 deletions .github/workflows/publish-stable.yml

This file was deleted.

78 changes: 78 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: Publish Package

env:
ASSET_ID_STABLE: 6573728888

on:
workflow_dispatch:
release:
types: [published]

jobs:
publish-public:
runs-on: ubuntu-latest
timeout-minutes: 8

steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Test Roblox Login Tokens
shell: bash
run: |
if [ -z "${{ secrets.ROBLOSECURITY }}" ]; then
echo "No cookie found. Please set the ROBLOSECURITY secret."
exit 1
fi
RBX_USERNAME=$(curl -s -X GET -H "Cookie: .ROBLOSECURITY=${{ secrets.ROBLOSECURITY }}" https://users.roblox.com/v1/users/authenticated | jq -r ".name")
if [ -z "$RBX_USERNAME" ]; then
echo "ROBLOSECURITY is invalid or expired. Please reset the ROBLOSECURITY secret."
exit 1
fi
echo "Logged in as $RBX_USERNAME."
- name: Setup Node LTS
uses: actions/setup-node@v2
with:
node-version: lts

- name: Setup Toolchain
uses: Roblox/setup-foreman@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}

- name: Report Tool Versions
run: |
foreman list
npm -v
node -v
- name: Install Dependencies
run: |
npm install
wally install
- name: Remove Tests
run: |
find . -name "*.spec.lua" -delete
- name: Publish to Roblox
if: ${{ github.event.release.prerelease == false }}
shell: bash
run: rojo upload default.project.json --asset_id $ASSET_ID_STABLE --cookie "${{ secrets.ROBLOSECURITY }}"

- name: Publish to Wally
env:
WALLY_TOKEN: ${{ secrets.WALLY_TOKEN }}
run: |
mkdir =p ~/.wally
printf "[tokens]\n\"https://api.wally.run/\" = \"%s\"" "$WALLY_TOKEN" >> ~/.wally/auth.toml
wally publish
- name: Publish to NPM
uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
72 changes: 72 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Create GitHub Release

on:
workflow_dispatch:
branches:
- default

jobs:
create-release:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Ensure Wally+NPM Version Numbers Match
run: |
NPM_VERSION=$( jq -r '.version' package.json )
WALLY_VERSION=$( grep -Po '(?<=version = ")([^"]+)' wally.toml )
if [ -z "$NPM_VERSION" ]; then
echo "NPM version not found in package.json"
exit 1
fi
if [ -z "$WALLY_VERSION" ]; then
echo "Wally version not found in wally.toml"
exit 1
fi
if [ "$WALLY_VERSION" != "$NPM_VERSION" ]; then
echo "Wally version ($WALLY_VERSION) does not match NPM version ($NPM_VERSION)"
exit 1
fi
- name: Setup Toolchain
uses: Roblox/setup-foreman@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: "^1.0.1"

- name: Report Tool Versions
run: foreman list

- name: Get Release Details
shell: bash
run: echo "PROJECT_VERSION=`grep -Po '(?<=version = ")([^"]+)' wally.toml`" >> $GITHUB_ENV

- name: Set Release Filename
shell: bash
run: |
echo "RELEASE_FILENAME=${{ github.event.repository.name }}-$PROJECT_VERSION.rbxm" >> $GITHUB_ENV
- name: Install Dependencies
run: wally install

- name: Remove Tests
run: |
find . -name "*.spec.lua" -delete
- name: Build Project
run: rojo build default.project.json -o $RELEASE_FILENAME

- name: Create GitHub Release
uses: softprops/action-gh-release@v1
with:
name: ${{ env.PROJECT_VERSION }}
tag_name: ${{ env.PROJECT_VERSION }}
fail_on_unmatched_files: true
files: |
${{ env.RELEASE_FILENAME }}
draft: true
41 changes: 0 additions & 41 deletions .github/workflows/unit-tests.yml

This file was deleted.

1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ node_modules/
*.tsbuildinfo
include/
out/
build/
*packages/
4 changes: 3 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
"kampfkarren.selene-vscode",
"nightrains.robloxlsp",
"evaera.vscode-rojo",
"redhat.vscode-yaml"
"redhat.vscode-yaml",
"johnnymorganz.stylua",
"bungcip.better-toml"
]
}
8 changes: 5 additions & 3 deletions .vscode/scripts/run-tests.ps1
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
$FILE_NAME = "test-place"

foreman install
rojo build .\test.project.json -o .\test-place.rbxlx
run-in-roblox --place .\test-place.rbxlx --script .\test-runner.server.lua
Remove-Item -Force .\test-place.rbxlx
rojo build .\test.project.json -o ".\$FILE_NAME.rbxl"
run-in-roblox --place ".\$FILE_NAME.rbxl" --script ".\test-runner.server.lua"
Remove-Item -Force ".\$FILE_NAME.rbxl"
9 changes: 6 additions & 3 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
{
"git.ignoreSubmodules": true,
"git.autoRepositoryDetection": "openEditors",
"git.detectSubmodules": false
"robloxLsp.diagnostics.severity": {
"unused-local": "Error",
"unused-function": "Error",
"unused-vararg": "Error",
"duplicate-index": "Error"
}
}
Loading

0 comments on commit a9ce295

Please sign in to comment.