Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement org membership based auth #147

Open
wants to merge 14 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
135 changes: 135 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
on:
workflow_call:
inputs:
tag:
required: true
type: string

upload_url:
required: true
type: string

release_ref:
required: true
type: string

overwrite:
required: true
type: boolean

release_name:
required: false
type: string

release_body:
required: false
type: string

jobs:
windows:
runs-on: windows-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- uses: Swatinem/rust-cache@v2

- name: Build release binary
run: cargo build --verbose --locked --release

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally.exe" staging/
cd staging
7z a ../release.zip *

- name: Upload Archive to Release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ inputs.tag }}
file: release.zip
asset_name: wally-${{ inputs.release_ref }}-win64.zip
overwrite: ${{ inputs.overwrite }}
release_name: ${{ inputs.release_name }}
body: ${{ inputs.release_body }}
prerelease: true

macos:
runs-on: macos-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- name: Install Rust
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y

- uses: Swatinem/rust-cache@v2

- name: Build release binary
run: |
source $HOME/.cargo/env
cargo build --verbose --locked --release
env:
OPENSSL_STATIC: 1

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally" staging/
cd staging
zip ../release.zip *

- name: Upload Archive to Release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ inputs.tag }}
file: release.zip
asset_name: wally-${{ inputs.release_ref }}-macos.zip
overwrite: ${{ inputs.overwrite }}
release_name: ${{ inputs.release_name }}
body: ${{ inputs.release_body }}
prerelease: true

linux:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- uses: Swatinem/rust-cache@v2

- name: Build
run: cargo build --locked --verbose --release
env:
OPENSSL_STATIC: 1

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally" staging/
cd staging
zip ../release.zip *

- name: Upload Archive to Release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ inputs.tag }}
file: release.zip
asset_name: wally-${{ inputs.release_ref }}-linux.zip
overwrite: ${{ inputs.overwrite }}
release_name: ${{ inputs.release_name }}
body: ${{ inputs.release_body }}
prerelease: true
48 changes: 48 additions & 0 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Nightly

on:
push:
branches:
- main
pull_request:
types: [labeled]

jobs:
fetch_tag:
if: |
github.event_name == 'push' ||
contains(github.event.pull_request.labels.*.name, 'built-as-nightly')
runs-on: ubuntu-latest
name: Build nightly release
outputs:
previous_tag: ${{ steps.previoustag.outputs.tag }}

steps:
- uses: actions/checkout@v2
with:
submodules: true

- name: 'Get Previous tag'
id: previoustag
uses: actions-ecosystem/action-get-latest-tag@v1
with:
semver_only: true

- name: Output tag
shell: bash
run: echo "tag=${{ steps.previoustag.outputs.tag }}" >> "$GITHUB_OUTPUT"

build:
uses: ./.github/workflows/build.yml
needs: fetch_tag
with:
tag: nightly
upload_url: https://uploads.github.com/repos/UpliftGames/wally/releases/108261310/assets{?name,label}
release_ref: ${{ needs.fetch_tag.outputs.previous_tag }}-nightly
overwrite: true
release_name: "Nightly 🌙 "
release_body: |
### For those who live life on the edge 🔪🩸😎

⚠️ Not suitable for production use
🚀 Built from latest main commit
136 changes: 11 additions & 125 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ name: Release

on:
push:
tags: ["*"]
tags: ["v*"]

jobs:
create-release:
if: endsWith(github.ref, 'main')
name: Create Release
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
upload_url: ${{ steps.create-release.outputs.upload_url }}
steps:
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -22,125 +22,11 @@ jobs:
draft: true
prerelease: false

windows:
needs: ["create-release"]
runs-on: windows-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- uses: Swatinem/rust-cache@v2

- name: Build release binary
run: cargo build --verbose --locked --release

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally.exe" staging/
cd staging
7z a ../release.zip *

- name: Upload Archive 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: release.zip
asset_name: wally-${{github.ref_name}}-win64.zip
asset_content_type: application/octet-stream

- name: Upload artifacts
uses: actions/upload-artifact@v1
with:
name: wally-${{ github.ref_name }}-win64.zip
path: release.zip

macos:
needs: ["create-release"]
runs-on: macos-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- name: Install Rust
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y

- uses: Swatinem/rust-cache@v2

- name: Build release binary
run: |
source $HOME/.cargo/env
cargo build --verbose --locked --release
env:
OPENSSL_STATIC: 1

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally" staging/
cd staging
zip ../release.zip *

- name: Upload Archive 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: release.zip
asset_name: wally-${{ github.ref_name }}-macos.zip
asset_content_type: application/octet-stream

- name: Upload artifacts
uses: actions/upload-artifact@v1
with:
name: wally-${{ github.ref_name }}-macos.zip
path: release.zip

linux:
needs: ["create-release"]
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
with:
submodules: true

- uses: Swatinem/rust-cache@v2

- name: Build
run: cargo build --locked --verbose --release
env:
OPENSSL_STATIC: 1

- name: Create Release Archive
shell: bash
run: |
mkdir staging
cp "target/release/wally" staging/
cd staging
zip ../release.zip *

- name: Upload Archive 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: release.zip
asset_name: wally-${{ github.ref_name }}-linux.zip
asset_content_type: application/octet-stream

- name: Upload artifacts
uses: actions/upload-artifact@v1
with:
name: wally-${{ github.ref_name }}-linux.zip
path: release.zip
build-release:
uses: ./.github/workflows/build.yml
needs: create-release
with:
tag: ${{ github.ref_name }}
upload_url: ${{ needs.create-release.outputs.upload_url }}
release_ref: ${{ github.ref_name }}
overwrite: false
1 change: 1 addition & 0 deletions .github/workflows/test-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
types: [labeled]
jobs:
merge-branch:
if: contains(github.event.pull_request.labels.*.name, 'merged to test')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
21 changes: 19 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,23 @@
# Contribution guide for wally

More info will be added here in the future. For now, if you want changes then please add an issue or create a PR! All issues, PRs, and comments on PRs are incredibly helpful. It may take us a while to get to your PR but if you feel it is important then please head to the #wally channel in the Roblox OSS discord server (find this in the top right of [wally.run](https://wally.run/)) and give us a ping!
Please respect that wally is still in early stages of development. Things are messy. Time is precious. We may be slow.

- **Only start making a PR if you are confident with Rust or TS/React** (issues and comments are always appreciated though)
- **Documentation for developing exists but may be outdated**
- **Be prepared to figure out how to get things going**
- **Fixing up any issues you do have getting going is a fantastic way to start helping!**
- **Polish and refine PRs as much as possible and ensure they pass CI checks before requesting a review**
- **If you want advise on a draft then discuss it in [#wally] first.**

Beyond that we are pretty chill, I promise! If you make good changes I will do my best to help you get them to the finish line.

More info will be added here in the future. For now, if you want changes then please add an issue or create a PR! All issues, PRs, and comments on PRs are incredibly helpful. It may take us a while to get to your PR but if you feel it is important then please head to the [#wally] channel in the Roblox OSS discord server (find this in the top right of [wally.run](https://wally.run/)) and let us know!

The current lead maintainer for wally is @magnalite, that's me! If you want to work on a complex change or feel like your pr/issue has gone unnoticed for too long then give me a ping in [#wally]!

Finally, as you may have guessed by now... If in doubt head to [#wally] and ask. Anyone is welcome to come in and ask anything about wally.

[#wally]: https://discord.com/channels/385151591524597761/872225914149302333

## Creating a new wally release

Expand All @@ -20,4 +37,4 @@ More info will be added here in the future. For now, if you want changes then pl
7. Push `git push && git push --tags`
8. Update release information

(Thank you to lpg / rojo for inspiration for this release checklist)
(Thank you to lpg / rojo for inspiration for this release checklist)
Loading
Loading