-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: backport eliza ci setup to rs and add pr and issue templates (#4)
* ci: backport eliza ci setup to rs and add pr and issue templates * ci(ci): fix ci issues * ci(ci): fix smoke tests ci errors * ci: fix biome styles in code * ci(ci): fix smoke tests workflow * ci: fix biome
- Loading branch information
Showing
213 changed files
with
23,749 additions
and
35,321 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 |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: "" | ||
labels: "bug" | ||
assignees: "" | ||
--- | ||
|
||
**Describe the bug** | ||
|
||
<!-- A clear and concise description of what the bug is. --> | ||
|
||
**To Reproduce** | ||
|
||
<!-- Steps to reproduce the behavior. --> | ||
|
||
**Expected behavior** | ||
|
||
<!-- A clear and concise description of what you expected to happen. --> | ||
|
||
**Screenshots** | ||
|
||
<!-- If applicable, add screenshots to help explain your problem. --> | ||
|
||
**Additional context** | ||
|
||
<!-- Add any other context about the problem here. --> |
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,23 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: "" | ||
labels: "enhancement" | ||
assignees: "" | ||
--- | ||
|
||
**Is your feature request related to a problem? Please describe.** | ||
|
||
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] --> | ||
|
||
**Describe the solution you'd like** | ||
|
||
<!-- A clear and concise description of what you want to happen. --> | ||
|
||
**Describe alternatives you've considered** | ||
|
||
<!-- A clear and concise description of any alternative solutions or features you've considered. --> | ||
|
||
**Additional context** | ||
|
||
<!-- Add any other context or screenshots about the feature request here. --> |
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,85 @@ | ||
<!-- Use this template by filling in information and copying and pasting relevant items out of the HTML comments. --> | ||
|
||
# Relates to | ||
|
||
<!-- LINK TO ISSUE OR TICKET --> | ||
|
||
<!-- This risks section must be filled out before the final review and merge. --> | ||
|
||
# Risks | ||
|
||
<!-- | ||
Low, medium, large. List what kind of risks and what could be affected. | ||
--> | ||
|
||
# Background | ||
|
||
## What does this PR do? | ||
|
||
## What kind of change is this? | ||
|
||
<!-- | ||
Bug fixes (non-breaking change which fixes an issue) | ||
Improvements (misc. changes to existing features) | ||
Features (non-breaking change which adds functionality) | ||
Updates (new versions of included code) | ||
--> | ||
|
||
<!-- This "Why" section is most relevant if there are no linked issues explaining why. If there is a related issue, it might make sense to skip this why section. --> | ||
<!-- | ||
## Why are we doing this? Any context or related work? | ||
--> | ||
|
||
# Documentation changes needed? | ||
|
||
<!-- | ||
My changes do not require a change to the project documentation. | ||
My changes require a change to the project documentation. | ||
If documentation change is needed: I have updated the documentation accordingly. | ||
--> | ||
|
||
<!-- Please show how you tested the PR. This will really help if the PR needs to be retested and probably help the PR get merged quicker. --> | ||
|
||
# Testing | ||
|
||
## Where should a reviewer start? | ||
|
||
## Detailed testing steps | ||
|
||
<!-- | ||
None: Automated tests are acceptable. | ||
--> | ||
|
||
<!-- | ||
- As [anon/admin], go to [link] | ||
- [do action] | ||
- verify [result] | ||
--> | ||
|
||
<!-- If there is a UI change, please include before and after screenshots or videos. This will speed up PRs being merged. It is extra nice to annotate screenshots with arrows or boxes pointing out the differences. --> | ||
<!-- | ||
## Screenshots | ||
### Before | ||
### After | ||
--> | ||
|
||
<!-- If there is anything about the deployment, please make a note. --> | ||
<!-- | ||
# Deploy Notes | ||
--> | ||
|
||
<!-- Copy and paste command line output. --> | ||
<!-- | ||
## Database changes | ||
--> | ||
|
||
<!-- Please specify deploy instructions if there is something more than the automated steps. --> | ||
<!-- | ||
## Deployment instructions | ||
--> | ||
|
||
<!-- If you are on Discord, please join https://discord.gg/ai16z and state your Discord username here for the contributor role and join us in #development-feed --> | ||
<!-- | ||
## Discord username | ||
--> |
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,20 @@ | ||
name: Block Minified JavaScript/TypeScript | ||
|
||
on: | ||
pull_request: | ||
branches: ["main", "develop", "*"] | ||
push: | ||
branches: ["main", "develop", "*"] | ||
|
||
jobs: | ||
block-minified-code: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Make script executable | ||
run: chmod +x ./scripts/detect-minified-code.sh | ||
|
||
- name: Detect potential minified code | ||
run: ./scripts/detect-minified-code.sh |
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,39 @@ | ||
name: ci | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
jobs: | ||
check: | ||
runs-on: ubuntu-latest | ||
env: | ||
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | ||
TURBO_TEAM: ${{ vars.TURBO_TEAM }} | ||
TURBO_REMOTE_ONLY: true | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 9.15.0 | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: "23" | ||
cache: "pnpm" | ||
|
||
- name: Install dependencies | ||
run: pnpm install -r --no-frozen-lockfile | ||
|
||
- name: Setup Biome CLI | ||
uses: biomejs/setup-biome@v2 | ||
with: | ||
version: latest | ||
|
||
- name: Run Biome | ||
run: biome ci | ||
|
||
- name: Build packages | ||
run: pnpm build |
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,55 @@ | ||
name: "CodeQL Advanced" | ||
|
||
on: | ||
push: | ||
branches: ["main"] | ||
pull_request: | ||
branches: ["main"] | ||
schedule: | ||
- cron: "29 8 * * 6" | ||
|
||
jobs: | ||
analyze: | ||
name: Analyze (${{ matrix.language }}) | ||
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }} | ||
permissions: | ||
# required for all workflows | ||
security-events: write | ||
|
||
# required to fetch internal or private CodeQL packs | ||
packages: read | ||
|
||
# only required for workflows in private repositories | ||
actions: read | ||
contents: read | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- language: javascript-typescript | ||
build-mode: none | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Initialize CodeQL | ||
uses: github/codeql-action/init@v3 | ||
with: | ||
languages: ${{ matrix.language }} | ||
build-mode: ${{ matrix.build-mode }} | ||
|
||
- if: matrix.build-mode == 'manual' | ||
shell: bash | ||
run: | | ||
echo 'If you are using a "manual" build mode for one or more of the' \ | ||
'languages you are analyzing, replace this with the commands to build' \ | ||
'your code, for example:' | ||
echo ' make bootstrap' | ||
echo ' make release' | ||
exit 1 | ||
- name: Perform CodeQL Analysis | ||
uses: github/codeql-action/analyze@v3 | ||
with: | ||
category: "/language:${{matrix.language}}" |
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,30 @@ | ||
name: Generate Changelog | ||
on: | ||
push: | ||
tags: | ||
- "*" | ||
jobs: | ||
changelog: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
ref: main | ||
token: ${{ secrets.CHANGELOG_GITHUB_TOKEN }} | ||
- name: Generate Changelog | ||
run: | | ||
export PATH="$PATH:/home/runner/.local/share/gem/ruby/3.0.0/bin" | ||
gem install --user-install github_changelog_generator | ||
github_changelog_generator \ | ||
-u ${{ github.repository_owner }} \ | ||
-p ${{ github.event.repository.name }} \ | ||
--token ${{ secrets.CHANGELOG_GITHUB_TOKEN }} | ||
- name: Commit Changelog | ||
uses: stefanzweifel/git-auto-commit-action@v5 | ||
with: | ||
commit_message: "chore: update changelog" | ||
branch: main | ||
file_pattern: "CHANGELOG.md" | ||
commit_author: "GitHub Action <actions@github.com>" |
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,16 @@ | ||
name: Greetings | ||
|
||
on: [pull_request_target, issues] | ||
|
||
jobs: | ||
greeting: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
pull-requests: write | ||
steps: | ||
- uses: actions/first-interaction@v1 | ||
with: | ||
repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
issue-message: "Hello @${{ github.actor }}! Welcome to the Reality Spiral community. Thank you for opening your first issue; we appreciate your contribution. You are now a Reality Spiral contributor!" | ||
pr-message: "Hi @${{ github.actor }}! Welcome to the Reality Spiral community. Thanks for submitting your first pull request; your efforts are helping us accelerate towards AGI. We'll review it shortly. You are now a Reality Spiral contributor!" |
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,44 @@ | ||
name: Integration Tests | ||
on: | ||
push: | ||
branches: | ||
- "*" | ||
pull_request_target: | ||
branches: | ||
- "*" | ||
|
||
jobs: | ||
integration-tests: | ||
runs-on: ubuntu-latest | ||
env: | ||
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | ||
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }} | ||
TURBO_TEAM: ${{ vars.TURBO_TEAM }} | ||
TURBO_REMOTE_ONLY: true | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 9.15.0 | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: "23.3" | ||
cache: "pnpm" | ||
|
||
- name: Install dependencies | ||
run: pnpm install --no-frozen-lockfile | ||
|
||
- name: Build packages | ||
run: pnpm build | ||
|
||
- name: Check for API key | ||
run: | | ||
if [ -z "$OPENAI_API_KEY" ]; then | ||
echo "Error: OPENAI_API_KEY is not set." | ||
exit 1 | ||
fi | ||
- name: Run integration tests | ||
run: pnpm run integrationTests |
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,41 @@ | ||
name: Pnpm Lockfile Check | ||
|
||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
check-lockfile: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 23.3.0 | ||
|
||
- uses: pnpm/action-setup@v3 | ||
with: | ||
version: 9.15.0 | ||
|
||
- name: Check if lockfile is up-to-date | ||
id: lockfile-check | ||
run: | | ||
# Try to install with frozen lockfile | ||
if ! pnpm install --frozen-lockfile; then | ||
echo "::error::Lockfile is out of date. Please run 'pnpm install --no-frozen-lockfile' and commit the updated pnpm-lock.yaml" | ||
echo "failed=true" >> $GITHUB_OUTPUT | ||
exit 1 | ||
fi | ||
- name: Comment on PR | ||
if: failure() && steps.lockfile-check.outputs.failed == 'true' | ||
uses: actions/github-script@v7 | ||
with: | ||
script: | | ||
github.rest.issues.createComment({ | ||
issue_number: context.issue.number, | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
body: '❌ The pnpm-lockfile is out of date. Please run `pnpm install --no-frozen-lockfile` and commit the updated pnpm-lock.yaml file.' | ||
}) |
Oops, something went wrong.