-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lint and upload roblox plugin to release & ci/cd changes
- Loading branch information
Showing
3 changed files
with
66 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,29 +22,82 @@ jobs: | |
release_name: ${{ github.ref }} | ||
draft: true | ||
|
||
release: | ||
build plugin: | ||
runs-on: ubuntu-latest | ||
needs: ["create-release"] | ||
name: Build Roblox Studio Plugin | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ok-nick/[email protected] | ||
|
||
- name: Run selene | ||
run: selene src | ||
working-directory: plugin | ||
|
||
- name: Run stylua | ||
run: stylua -c src | ||
working-directory: plugin | ||
|
||
- name: Generate sourcemap | ||
run: rojo sourcemap default.project.json --output sourcemap.json | ||
working-directory: plugin | ||
|
||
- name: Download global Roblox types | ||
shell: bash | ||
run: curl -s -O https://raw.githubusercontent.com/JohnnyMorganz/luau-lsp/master/scripts/globalTypes.d.lua | ||
|
||
- name: Run Luau Analyze | ||
run: luau-lsp analyze --sourcemap=sourcemap.json --defs=../globalTypes.d.lua --no-strict-dm-types src | ||
working-directory: plugin | ||
|
||
- name: Build Plugin | ||
run: rojo build plugin -o Plugin.rbxm | ||
|
||
- name: Upload artifacts | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: Plugin.rbxm | ||
path: Plugin.rbxm | ||
|
||
- name: Upload Plugin to Release | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ needs.create-release.outputs.upload_url }} | ||
asset_path: Plugin.rbxm | ||
asset_name: Plugin.rbxm | ||
asset_content_type: application/octet-stream | ||
|
||
build exe: | ||
runs-on: ubuntu-latest | ||
needs: ["create-release"] | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
|
||
- name: Install dependencies | ||
run: npm install | ||
- name: Build | ||
- | ||
|
||
- name: Build with Nexe | ||
run: node build.js | ||
|
||
- name: Upload Binary Artifact | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: StyLua-Plugin | ||
path: out/StyLua-Plugin.exe | ||
name: StyLua-Roblox.exe | ||
path: StyLua-Roblox.exe | ||
|
||
- name: Upload release assets to GitHub | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ needs.create-release.outputs.upload_url }} | ||
asset_path: out/StyLua-Plugin.exe | ||
asset_name: StyLua-Plugin.exe | ||
asset_path: StyLua-Roblox.exe | ||
asset_name: StyLua-Roblox.exe | ||
asset_content_type: application/octet-stream |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[tools] | ||
rojo = "rojo-rbx/[email protected]" | ||
luau-lsp = "JohnnyMorganz/[email protected]" | ||
stylua = "JohnnyMorganz/[email protected]" | ||
selene = "Kampfkarren/[email protected]" |