forked from ubiquity/pay.ubq.fi
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
22 changed files
with
12,128 additions
and
7,376 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 |
---|---|---|
|
@@ -31,6 +31,7 @@ | |
"mswjs", | ||
"Numberish", | ||
"outdir", | ||
"outfile", | ||
"pageable", | ||
"Reloadly", | ||
"Rpcs", | ||
|
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,149 @@ | ||
plugins: | ||
- uses: | ||
- plugin: https://ubiquibot-command-wallet-development.ubiquity.workers.dev | ||
- uses: | ||
- plugin: https://ubiquibot-command-query-user-development.ubiquity.workers.dev | ||
with: | ||
allowPublicQuery: true | ||
- uses: | ||
- plugin: https://ubiquibot-assistive-pricing-development.ubiquity.workers.dev | ||
with: | ||
labels: | ||
time: | ||
- "Time: <1 Hour" | ||
- "Time: <2 Hours" | ||
- "Time: <4 Hours" | ||
- "Time: <1 Day" | ||
- "Time: <1 Week" | ||
- "Time: <1 Month" | ||
priority: | ||
- "Priority: 1 (Normal)" | ||
- "Priority: 2 (Medium)" | ||
- "Priority: 3 (High)" | ||
- "Priority: 4 (Urgent)" | ||
- "Priority: 5 (Emergency)" | ||
basePriceMultiplier: 2 | ||
publicAccessControl: | ||
setLabel: true | ||
fundExternalClosedIssue: false | ||
- skipBotEvents: false | ||
uses: | ||
- plugin: ubiquibot/conversation-rewards@development | ||
# we don't skip bot events so conversation rewards triggered by the bot also run | ||
with: | ||
evmNetworkId: 100 | ||
evmPrivateEncrypted: "bd5AFnSCO6c5jJyPifpOfr5Zys29RE7SyXkEU3akT13RtGmYDrqGIGuvJQyH53HA5dIba7PL5bXfll0JebmwXYe5gHIXSGX80WuGMDHh0cFfeGjHhmUXe8kkZ1OT2De9qRpqejJcEzdfi-8XNAvP7cQu2Vt-7RNnPw" # https://github.com/ubiquibot/conversation-rewards/pull/111#issuecomment-2348639931 | ||
erc20RewardToken: "0xC6ed4f520f6A4e4DC27273509239b7F8A68d2068" | ||
incentives: | ||
contentEvaluator: | ||
enabled: true | ||
userExtractor: | ||
enabled: true | ||
redeemTask: true | ||
dataPurge: | ||
enabled: true | ||
formattingEvaluator: | ||
multipliers: | ||
- role: [ISSUE_SPECIFICATION] | ||
multiplier: 3 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
html: | ||
br: 0 | ||
code: 5 | ||
p: 1 | ||
em: 0 | ||
img: 5 | ||
strong: 0 | ||
blockquote: 0 | ||
h1: 1 | ||
h2: 1 | ||
h3: 1 | ||
h4: 1 | ||
h5: 1 | ||
h6: 1 | ||
a: 5 | ||
li: 1 | ||
td: 1 | ||
hr: 0 | ||
- role: [ISSUE_AUTHOR] | ||
multiplier: 1 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.2 | ||
- role: [ISSUE_ASSIGNEE] | ||
multiplier: 1 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
- role: [ISSUE_COLLABORATOR] | ||
multiplier: 1 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
- role: [ISSUE_CONTRIBUTOR] | ||
multiplier: 0.25 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
- role: [PULL_SPECIFICATION] | ||
multiplier: 0 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0 | ||
- role: [PULL_AUTHOR] | ||
multiplier: 0 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.2 | ||
- role: [PULL_ASSIGNEE] | ||
multiplier: 1 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
- role: [PULL_COLLABORATOR] | ||
multiplier: 1 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
- role: [PULL_CONTRIBUTOR] | ||
multiplier: 0.25 | ||
rewards: | ||
regex: | ||
"\\b\\w+\\b": 0.1 | ||
permitGeneration: | ||
enabled: true | ||
githubComment: | ||
post: true | ||
debug: false | ||
- uses: | ||
- plugin: ubiquibot/user-activity-watcher@development | ||
with: | ||
watch: | ||
optOut: | ||
- ubiquibot | ||
- launch-party | ||
- staging | ||
- production | ||
- uses: | ||
- plugin: ubiquibot/automated-merging@development | ||
with: | ||
approvalsRequired: | ||
collaborator: 1 | ||
mergeTimeout: | ||
collaborator: "3.5 days" | ||
repos: | ||
ignore: | ||
- ubiquibot | ||
- launch-party | ||
- staging | ||
- production | ||
- uses: | ||
- plugin: https://ubiquibot-command-start-stop-development.ubiquity.workers.dev | ||
with: | ||
reviewDelayTolerance: "3 Days" | ||
taskStaleTimeoutDuration: "30 Days" | ||
startRequiresWallet: true # default is true | ||
- uses: | ||
- plugin: ubiquibot/issue-comment-embeddings@development |
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,70 @@ | ||
name: Sync branch to template | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: "14 0 1 * *" | ||
|
||
jobs: | ||
sync: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Get GitHub App token | ||
uses: tibdex/[email protected] | ||
id: get_installation_token | ||
with: | ||
app_id: ${{ secrets.APP_ID }} | ||
private_key: ${{ secrets.APP_PRIVATE_KEY }} | ||
|
||
- name: Sync branch to template | ||
env: | ||
GH_TOKEN: ${{ steps.get_installation_token.outputs.token }} | ||
run: | | ||
branch_name=$(git rev-parse --abbrev-ref HEAD) | ||
original_remote=$(git remote get-url origin) | ||
pr_branch="sync-template/${branch_name}" | ||
git config --global user.email "ubiquity-os[bot]@users.noreply.github.com" | ||
git config --global user.name "ubiquity-os[bot]" | ||
git remote add template https://github.com/ubiquity/ts-template.git | ||
git fetch template | ||
git checkout -b "$pr_branch" | ||
last_sync=$(git log --grep="Sync template" --format="%H" -n 1) | ||
if [ -n "$last_sync" ]; then | ||
# If there's a previous sync, try to cherry-pick new changes | ||
if ! git cherry-pick $last_sync..template/main; then | ||
# If cherry-pick fails, abort and try a merge instead | ||
git cherry-pick --abort | ||
git merge template/main --no-commit | ||
fi | ||
else | ||
# If it's the first sync, merge the template | ||
git merge template/main --allow-unrelated-histories --no-commit | ||
fi | ||
# Check if there are any changes | ||
if git diff --staged --quiet && git diff --quiet; then | ||
echo "No changes to sync from template." | ||
exit 0 | ||
fi | ||
# Commit changes, even if there are conflicts | ||
git commit -am "chore: sync template (with potential conflicts)" || true | ||
# Push changes and create PR | ||
git push -f "$original_remote" "$pr_branch" | ||
gh pr create --title "Sync branch to template (manual resolution required)" \ | ||
--body "This pull request merges changes from the template repository. There may be conflicts that require manual resolution." \ | ||
--head "$pr_branch" \ | ||
--base "$branch_name" || true |
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 |
---|---|---|
|
@@ -12,6 +12,7 @@ commit.txt | |
.pnp.loader.mjs | ||
.env | ||
static/dist | ||
static/bundles | ||
|
||
cypress/screenshots | ||
cypress/videos | ||
|
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
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 |
---|---|---|
@@ -1,18 +1,16 @@ | ||
import esbuild from "esbuild"; | ||
import { esBuildContext } from "./esbuild-build"; | ||
|
||
(async () => { | ||
await server(); | ||
})().catch((error) => { | ||
console.error("Unhandled error:", error); | ||
startServer().catch((error) => { | ||
console.error("Server startup error:", error); | ||
process.exit(1); | ||
}); | ||
|
||
export async function server() { | ||
const _context = await esbuild.context(esBuildContext); | ||
const { port } = await _context.serve({ | ||
async function startServer() { | ||
const context = await esbuild.context(esBuildContext); | ||
const { port } = await context.serve({ | ||
servedir: "static", | ||
port: 8080, | ||
}); | ||
console.log(`http://localhost:${port}`); | ||
console.log(`Server running at http://localhost:${port}`); | ||
} |
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,10 @@ | ||
{ | ||
"preset": "ts-jest", | ||
"testEnvironment": "node", | ||
"roots": ["./tests"], | ||
"coveragePathIgnorePatterns": ["node_modules", "mocks"], | ||
"collectCoverage": true, | ||
"coverageReporters": ["json", "lcov", "text", "clover", "json-summary"], | ||
"reporters": ["default", "jest-junit", "jest-md-dashboard"], | ||
"coverageDirectory": "coverage" | ||
} |
Oops, something went wrong.