Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
378 commits
Select commit Hold shift + click to select a range
b2ea8e2
Update ubiquibot-config.yml
0x4007 Aug 9, 2023
9a6f486
Merge branch 'development' into feat/add-default-price-label
wannacfuture Aug 9, 2023
d456927
feat: resolve conflicts
wannacfuture Aug 9, 2023
dd9b3f0
feat: fixed minor bugs
wannacfuture Aug 10, 2023
8f063f9
Merge branch 'ubiquity:development' into private-key-empty-error
Sadaf-A Aug 10, 2023
1579293
Update src/configs/strings.ts
wannacfuture Aug 10, 2023
f13face
Update src/configs/strings.ts
wannacfuture Aug 10, 2023
ddfef0f
Merge branch 'development' into feat/parent-issue-fix
wannacfuture Aug 10, 2023
bfee1dd
feat: resolve conflicts
wannacfuture Aug 10, 2023
105547f
Merge pull request #597 from wannacfuture/feat/parent-issue-fix
0x4007 Aug 10, 2023
674ada5
feat: slight change
wannacfuture Aug 10, 2023
53a23d3
feat: minor fix
wannacfuture Aug 10, 2023
f819542
Merge branch 'development' into feat/parent-issue-fix
wannacfuture Aug 10, 2023
505719f
Merge pull request #596 from ubiquity/pavlovcik-patch-2
0x4007 Aug 10, 2023
2abac46
Merge pull request #578 from seprintour/setup-policies
0x4007 Aug 10, 2023
1dc05fc
Merge branch 'development' into feat/parent-issue-fix
wannacfuture Aug 10, 2023
182c273
Update src/handlers/pricing/action.ts
wannacfuture Aug 10, 2023
144ed37
Update src/handlers/payout/action.ts
wannacfuture Aug 10, 2023
7469677
Merge branch 'ubiquity:development' into private-key-empty-error
Sadaf-A Aug 10, 2023
d45e2a5
Update ubiquibot-config.yml
Sadaf-A Aug 10, 2023
43194ed
Merge pull request #598 from wannacfuture/feat/parent-issue-fix
0x4007 Aug 10, 2023
78150c0
Update ubiquibot-config.yml, reverting changes
Sadaf-A Aug 10, 2023
d496752
build: remove unnecessary script
web4er Aug 11, 2023
8f6c8b2
docs: update existing info
web4er Aug 11, 2023
53eec75
docs: add manual method for local payment permits
web4er Aug 11, 2023
159a3c7
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 11, 2023
dfb48b1
Merge pull request #484 from wannacfuture/feat/add-default-price-label
cuddle-dev Aug 11, 2023
5cc126f
feat: use decimal.js
whilefoo Aug 11, 2023
69bd05e
Merge remote-tracking branch 'upstream/development' into html-comments
whilefoo Aug 11, 2023
9ce48e1
docs: improve docs English, remove typos
web4er Aug 11, 2023
75561cd
docs: update info for repo configs
web4er Aug 11, 2023
7e9c469
fix: make it optional
cuddle-dev Aug 12, 2023
c1b218a
chore: make persistSession false
cuddle-dev Aug 12, 2023
82a2e26
chore: any type
cuddle-dev Aug 12, 2023
d4d6a8d
fix: query regex
EtherealGlow Aug 12, 2023
6aa91c8
fix: query regex
EtherealGlow Aug 12, 2023
59a6fc7
Update query.ts
EtherealGlow Aug 12, 2023
d8dff67
feat: add description for permits
whilefoo Aug 12, 2023
6268d44
fix: query regex
EtherealGlow Aug 12, 2023
a2daa60
fix: query regex
EtherealGlow Aug 12, 2023
bb80223
fix: switch back to json and remove strip-json-comments dependency
0x4007 Aug 12, 2023
61b4dd0
Merge branch 'development' into pavlovcik-patch-1
0x4007 Aug 12, 2023
2e31b3f
Merge pull request #594 from ubiquity/pavlovcik-patch-1
0x4007 Aug 13, 2023
24c11e7
Merge pull request #611 from EtherealGlow/development-7
0x4007 Aug 13, 2023
7c6f399
feat: update default config and README
whilefoo Aug 13, 2023
371f13c
chore: refactor issue creator multiplier
gitcoindev Aug 8, 2023
d4e2b96
chore: better logging
cuddle-dev Aug 14, 2023
33a17f0
chore: new migration
cuddle-dev Aug 14, 2023
e9cfb82
Merge pull request #614 from ubiquity/complete-row-security
cuddle-dev Aug 14, 2023
0548f10
Merge branch 'development' into refactor-issue-creator-multiplier
gitcoindev Aug 14, 2023
c164a6c
feat: add workflow to update params
EtherealGlow Aug 14, 2023
45bf48d
feat: add workflow to update params
EtherealGlow Aug 14, 2023
27cecdc
chore: set default issue creator multiplier to 2
gitcoindev Aug 14, 2023
838e7a4
feat: new policy
cuddle-dev Aug 14, 2023
84657d0
fix: with check
cuddle-dev Aug 14, 2023
2051c1d
fix: insert policy
cuddle-dev Aug 14, 2023
202a831
chore: docs update
cuddle-dev Aug 14, 2023
93dd8c9
feat: add workflow to update param names
EtherealGlow Aug 14, 2023
d30e698
feat: add workflow to update param names
EtherealGlow Aug 14, 2023
fb379e5
feat: add workflow to update param names
EtherealGlow Aug 14, 2023
d56a523
chore: revert due to use of service key
cuddle-dev Aug 14, 2023
974e8b9
feat: add workflow to update param names
EtherealGlow Aug 15, 2023
4d0b38b
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 15, 2023
14e8cd8
Merge remote-tracking branch 'upstream/development' into html-comments
whilefoo Aug 15, 2023
c728233
feat: added checks
whilefoo Aug 15, 2023
0863b69
feat: error handling and change column type to text
whilefoo Aug 15, 2023
f26c96a
chore: remove multiplier from comments on issue reward
gitcoindev Aug 16, 2023
b89e8db
feat: check permission
wannacfuture Aug 16, 2023
8824ffd
Update src/handlers/payout/action.ts
0x4007 Aug 16, 2023
483e42e
fix: upsert user
whilefoo Aug 16, 2023
e0e8abf
fix: weekly
whilefoo Aug 16, 2023
401f40b
docs: add info about possible ways to QA
web4er Aug 16, 2023
b02abc3
docs: use correct env variable name
web4er Aug 16, 2023
6dc6e85
feat: correct primary key for access
whilefoo Aug 16, 2023
07eef90
fix: accidental condition, user.name can be undefined
whilefoo Aug 16, 2023
0b3edda
feat: improve code
whilefoo Aug 16, 2023
520957c
Update src/helpers/issue.ts
wannacfuture Aug 16, 2023
f320526
Update src/helpers/issue.ts
wannacfuture Aug 16, 2023
d253e4f
feat: derive weight automatically
Nick-Legend Aug 17, 2023
911766b
fix: removed weight from readme
Nick-Legend Aug 17, 2023
7975feb
Merge branch 'development' of https://github.com/byteballet/ubiquibot…
Nick-Legend Aug 17, 2023
7c7ce70
fix: pulled dev branch
Nick-Legend Aug 17, 2023
9013519
fix: match text
whilefoo Aug 17, 2023
d2dcb5b
feat: status check
wannacfuture Aug 17, 2023
6a2ecf0
Merge branch 'feat/check-permission' of https://github.com/wannacfutu…
wannacfuture Aug 17, 2023
979abc3
docs: fix pricing formula & wordings
web4er Aug 17, 2023
189f408
docs: update steps to QA using local instance only
web4er Aug 17, 2023
8511995
Merge branch 'development' into update-docs
web4er Aug 17, 2023
0fb3ef6
docs: update wordings
web4er Aug 17, 2023
27beaa8
docs: update wordings
web4er Aug 17, 2023
7ed629d
docs: update wordings
web4er Aug 17, 2023
3542c8e
docs: update wordings
web4er Aug 17, 2023
ec0d3fe
docs: update wordings
web4er Aug 17, 2023
0efedcc
docs: add period where seems appropriate
web4er Aug 17, 2023
a8615c3
Update src/helpers/issue.ts
wannacfuture Aug 17, 2023
59825e4
fix: check permission when closing issue (#622)
wannacfuture Aug 17, 2023
6c4649e
feat: add workflow to update param names
EtherealGlow Aug 17, 2023
470cac8
Update update-config.yml
EtherealGlow Aug 17, 2023
3492592
Merge branch 'development' into refactor-issue-creator-multiplier
0x4007 Aug 17, 2023
0316b26
Merge branch 'development' into development-3
0x4007 Aug 17, 2023
0a2d848
feat: add check for max permit price
whilefoo Aug 17, 2023
cac4b02
fix: typo
whilefoo Aug 17, 2023
759dce0
Merge branch 'development' into html-comments
0x4007 Aug 17, 2023
4bb7d5c
Merge branch 'development' into automatically_derive_weight
0x4007 Aug 17, 2023
1c442aa
Merge branch 'development' of https://github.com/byteballet/ubiquibot…
Nick-Legend Aug 17, 2023
2be2db9
feat: test
wannacfuture Aug 17, 2023
4cb7501
feat: test
wannacfuture Aug 17, 2023
ae5f1e7
Merge branch 'development' into feat/check-permission
wannacfuture Aug 17, 2023
ab49d26
fix: weight from priority-label
Nick-Legend Aug 17, 2023
5b9edf8
Merge branch 'automatically_derive_weight' of https://github.com/byte…
Nick-Legend Aug 17, 2023
734dce9
feat: add instruction
wannacfuture Aug 17, 2023
2253bb7
Merge branch 'feat/check-permission' of https://github.com/wannacfutu…
wannacfuture Aug 17, 2023
fc5cfa5
feat: typo
wannacfuture Aug 17, 2023
b06587f
Merge pull request #617 from EtherealGlow/development-3
0x4007 Aug 18, 2023
f6e99df
feat: create a migration of logs table for devpanther
cuddle-dev Aug 18, 2023
5ca5331
feat: add permission check
wannacfuture Aug 18, 2023
09dd22f
docs: fix price formula
web4er Aug 18, 2023
89270ea
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 18, 2023
244c088
Merge branch 'development' of https://github.com/byteballet/ubiquibot…
Nick-Legend Aug 18, 2023
613ff57
chore: creating deploy script
devpanther Aug 18, 2023
23c97fe
chore: testing script
devpanther Aug 18, 2023
7c78ef1
chore: testing script
devpanther Aug 18, 2023
166a388
chore: testing script
devpanther Aug 18, 2023
a1706d7
chore: testing env
devpanther Aug 18, 2023
0c67cb7
chore: setting up functions
devpanther Aug 18, 2023
9c5ff7e
chore: setting up functions
devpanther Aug 18, 2023
e84b9e5
chore: setting up functions
devpanther Aug 18, 2023
6c20ac3
chore: setting up functions ts
devpanther Aug 18, 2023
3389e20
fix: parse priority
Nick-Legend Aug 18, 2023
57d2db5
chore: setting up functions ts
devpanther Aug 18, 2023
603676b
chore: setting up functions ts
devpanther Aug 18, 2023
25d089a
chore: setting up functions ts
devpanther Aug 18, 2023
4ba0573
chore: setting up functions ts
devpanther Aug 18, 2023
2542561
chore: setting up functions ts
devpanther Aug 18, 2023
a521b46
chore: setting up functions ts
devpanther Aug 18, 2023
ab2cb58
chore: setting up functions ts
devpanther Aug 18, 2023
760eda6
chore: setting up functions ts
devpanther Aug 18, 2023
80a4351
chore: setting up functions ts
devpanther Aug 18, 2023
729306a
chore: setting up functions ts
devpanther Aug 18, 2023
f57d47f
chore: setting up functions ts
devpanther Aug 18, 2023
90c731b
Merge branch 'development' into update-docs
web4er Aug 18, 2023
a5b1d88
chore: finalize function setup
devpanther Aug 18, 2023
c488208
chore: finalize function setup
devpanther Aug 18, 2023
145c02f
chore: finalize function setup
devpanther Aug 18, 2023
4bbe1a6
chore: checking env
devpanther Aug 18, 2023
79a56f7
chore: checking env
devpanther Aug 18, 2023
d3c2e3f
chore: installed supabase to function
devpanther Aug 18, 2023
624c375
chore: setting up websocket
devpanther Aug 18, 2023
696663f
chore: ws connection on html
devpanther Aug 18, 2023
8fc1d6b
chore: ws connection on html
devpanther Aug 19, 2023
8d70eee
chore: ws connection on html
devpanther Aug 19, 2023
4e091c6
chore: ws connection on html
devpanther Aug 19, 2023
60665e3
chore: checking receiving end on client
devpanther Aug 19, 2023
dc13b1c
chore: checking receiving end on client
devpanther Aug 19, 2023
b441897
chore: setting up supabase realtime watcher
devpanther Aug 19, 2023
91c45b1
chore: no event from supabase
devpanther Aug 19, 2023
32ea480
chore: no event from supabase
devpanther Aug 19, 2023
cf70ed3
chore: no event from supabase
devpanther Aug 19, 2023
82fcbc8
chore: no event from supabase
devpanther Aug 19, 2023
92907e9
chore: no event from supabase
devpanther Aug 19, 2023
4704a33
chore: no event from supabase
devpanther Aug 19, 2023
83aedae
chore: switch to Github workers
devpanther Aug 19, 2023
05c26d6
chore: install wrangler
devpanther Aug 19, 2023
a79dd59
chore: install wrangler
devpanther Aug 19, 2023
d4efc3e
chore: deploy before set env
devpanther Aug 19, 2023
0f8863e
chore: deploy before set env
devpanther Aug 19, 2023
79e518c
feat: read from env
EtherealGlow Aug 19, 2023
bffef7d
Merge branch 'development' into html-comments
0x4007 Aug 20, 2023
988f782
chore: setting up websocket
devpanther Aug 20, 2023
b79c6b7
chore: properly type the socket class
devpanther Aug 21, 2023
bdbd1da
chore: websocket works now
devpanther Aug 21, 2023
5752cc7
chore: clear toml file
devpanther Aug 21, 2023
0537cb6
Merge pull request #607 from web4er/update-docs
0x4007 Aug 21, 2023
7e48ebe
chore: switch back to pages for html support
devpanther Aug 21, 2023
4344214
chore: switch back to pages for html support
devpanther Aug 21, 2023
fee0dd9
feat: logs to supabase (#604)
devpanther Aug 22, 2023
24c146a
chore: setting up logger page
devpanther Aug 22, 2023
74329a1
chore: separating ts config
devpanther Aug 22, 2023
76d8dd2
chore: ignore all js files in local directory
devpanther Aug 22, 2023
2c66147
chore: logger setup done
devpanther Aug 22, 2023
fe8cf57
Merge branch 'development' into realtime-logger-app
devpanther Aug 22, 2023
44caa4b
chore: only run on workflow completed
devpanther Aug 22, 2023
8054782
chore: use esbuild for frontend scripts
devpanther Aug 22, 2023
5b4287a
chore: json on modal
devpanther Aug 22, 2023
0ab6dbb
chore: overflow long text
devpanther Aug 22, 2023
e6a4f63
chore: ignore log-app
devpanther Aug 22, 2023
1f0a6f7
Merge branch 'development' of https://github.com/byteballet/ubiquibot…
Nick-Legend Aug 22, 2023
00ff231
fix: remove value and weight
Nick-Legend Aug 22, 2023
ee91997
Merge branch 'development' into html-comments
whilefoo Aug 22, 2023
73b3322
chore: switch to frontend supabase
devpanther Aug 22, 2023
2854086
chore: table styling
devpanther Aug 22, 2023
1bd9db5
chore: scroll last log into view
devpanther Aug 22, 2023
761f575
chore: keys to constant
devpanther Aug 22, 2023
7da68cc
chore: scroll overflowing text
devpanther Aug 22, 2023
12777f0
Merge pull request #545 from whilefoo/html-comments
0x4007 Aug 22, 2023
b7438bd
feat: read from env
EtherealGlow Aug 22, 2023
c40bfe0
feat: read from env
EtherealGlow Aug 22, 2023
f7baf63
Merge branch 'development' into realtime-logger-app
devpanther Aug 22, 2023
b3372da
Merge remote-tracking branch 'ubi/development' into refactor-issue-cr…
gitcoindev Aug 22, 2023
51ebf6f
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 22, 2023
b9211ae
Update ubiquibot-config.yml
wannacfuture Aug 23, 2023
e405bb7
Merge pull request #658 from ubiquity/wannacfuture-patch-1
0x4007 Aug 23, 2023
5ff17bc
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 23, 2023
ff3035a
Merge branch 'development' into feat/check-permission
0x4007 Aug 23, 2023
c73cbc9
fix: skip wildcard handlers for push event
gitcoindev Aug 23, 2023
f4751d1
Merge pull request #636 from wannacfuture/feat/check-permission
0x4007 Aug 23, 2023
a3001a9
Merge commit '59825e4d7289a8da87bb3f568d9e69b183c821cf' into HEAD
0x4007 Aug 23, 2023
237686b
Update src/adapters/supabase/helpers/client.ts
0x4007 Aug 23, 2023
309022c
Merge pull request #661 from ubiquity/feat/security-update-august-2023
0x4007 Aug 23, 2023
1f109d1
Merge branch 'development' into fix-654-unexpected-unassign
0x4007 Aug 23, 2023
8646aa1
Merge pull request #660 from gitcoindev/fix-654-unexpected-unassign
0x4007 Aug 23, 2023
826d91b
Merge branch 'development' of https://github.com/byteballet/ubiquibot…
Nick-Legend Aug 23, 2023
3e4c7a8
update: remove value from ubiquibot-config
Nick-Legend Aug 23, 2023
e5c7502
Merge branch 'main' into development
cuddle-dev Aug 24, 2023
66ff9d3
chore: developer-friendly
cuddle-dev Aug 24, 2023
9fdb0e4
chore: update src/handlers/payout/post.ts
cuddle-dev Aug 24, 2023
f7a0041
Merge branch 'development' into automatically_derive_weight
0x4007 Aug 24, 2023
33206eb
Merge branch 'development' into refactor-issue-creator-multiplier
gitcoindev Aug 24, 2023
3288919
Merge branch 'development' into realtime-logger-app
0x4007 Aug 24, 2023
5982dc3
Merge branch 'development' into private-key-empty-error
0x4007 Aug 24, 2023
41ce93f
feat: read from env
EtherealGlow Aug 24, 2023
d8cfe7e
feat: read from env
EtherealGlow Aug 24, 2023
bb4ea82
Merge pull request #616 from gitcoindev/refactor-issue-creator-multip…
0x4007 Aug 25, 2023
47ebcd5
Merge branch 'development' into private-key-empty-error
0x4007 Aug 25, 2023
3e40c9c
Merge branch 'development' into automatically_derive_weight
0x4007 Aug 25, 2023
84c9097
chore: remove worker functions from exclude
devpanther Aug 25, 2023
87972b1
Merge branch 'development' into realtime-logger-app
devpanther Aug 25, 2023
0f9f3d6
Merge pull request #649 from devpanther/realtime-logger-app
0x4007 Aug 25, 2023
d2e48aa
feat: read from env
EtherealGlow Aug 26, 2023
756bff3
Merge branch 'development' into private-key-empty-error
Sadaf-A Aug 26, 2023
9c50296
Merge branch 'development' into development-2
0x4007 Aug 26, 2023
e65672b
Merge pull request #639 from EtherealGlow/development-2
0x4007 Aug 26, 2023
dead5a6
Merge branch 'development' into private-key-empty-error
0x4007 Aug 26, 2023
27205c3
Merge pull request #621 from ubiquity-whilefoo/db-fix
0x4007 Aug 26, 2023
0c57588
Merge pull request #582 from Sadaf-A/private-key-empty-error
whilefoo Aug 26, 2023
f03df47
fix: change time to fix migration error
whilefoo Aug 26, 2023
fb1599b
Merge pull request #627 from byteballet/automatically_derive_weight
whilefoo Aug 26, 2023
879d066
Merge pull request #671 from ubiquity-whilefoo/db-fix-2
0x4007 Aug 26, 2023
09ead61
Update ubiquibot-config.yml
0x4007 Aug 27, 2023
cef102d
refactor: remove redundant properties
0x4007 Aug 27, 2023
ef6e27e
refactor: this will also be controlled by org config
0x4007 Aug 27, 2023
8f36fbd
Merge pull request #677 from ubiquity/pavlovcik-patch-2
0x4007 Aug 27, 2023
5ef5f44
feat: check for Duplicate Specs (#608)
Nick-Legend Aug 27, 2023
0aecb85
feat: logs cleaner
Steveantor Aug 27, 2023
ab85a52
feat: add to codeowners
cuddle-dev Aug 29, 2023
9e53e1a
feat: add cron migration
Steveantor Aug 29, 2023
031b67e
feat: Logs Cleaner (#683)
cuddle-dev Aug 29, 2023
6771daa
feat: exploit issue resolved
cuddle-dev Aug 29, 2023
d0a7f79
fix: update CODEOWNERS
cuddle-dev Aug 30, 2023
41f3cb5
fix: allow regex
whilefoo Aug 31, 2023
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
7 changes: 7 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,10 @@ ANALYTICS_MODE=
# Use `trace` to get verbose logging or `info` to show less
LOG_LEVEL=debug
LOGDNA_INGESTION_KEY=
OPENAI_API_HOST=https://api.openai.com
OPENAI_API_KEY=
CHATGPT_USER_PROMPT_FOR_IMPORTANT_WORDS="I need your help to find important words (e.g. unique adjectives) from github issue below and I want to parse them easily so please separate them using #(No other contexts needed). Please separate the words by # so I can parse them easily. Please answer simply as I only need the important words. Here is the issue content.\n"
CHATGPT_USER_PROMPT_FOR_MEASURE_SIMILARITY='I have two github issues and I need to measure the possibility of the 2 issues are the same content (No other contents needed and give me only the number in %).\n Give me in number format and add % after the number.\nDo not tell other things since I only need the number (e.g. 85%). Here are two issues:\n 1. "%first%"\n2. "%second%"'
SIMILARITY_THRESHOLD=80
MEASURE_SIMILARITY_AI_TEMPERATURE=0
IMPORTANT_WORDS_AI_TEMPERATURE=0
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1 +1 @@

* @0xcodercrane
38 changes: 2 additions & 36 deletions .github/ubiquibot-config.yml
Original file line number Diff line number Diff line change
@@ -1,39 +1,5 @@
---
evm-network-id: 100
price-multiplier: 1.5
time-labels:
- name: "Time: <1 Hour"
weight: 0.125
value: 3600
- name: "Time: <1 Day"
weight: 1
value: 86400
- name: "Time: <1 Week"
weight: 2
value: 604800
- name: "Time: <2 Weeks"
weight: 3
value: 1209600
- name: "Time: <1 Month"
weight: 4
value: 2592000
priority-labels:
- name: "Priority: 0 (Normal)"
weight: 1
- name: "Priority: 1 (Medium)"
weight: 2
- name: "Priority: 2 (High)"
weight: 3
- name: "Priority: 3 (Urgent)"
weight: 4
- name: "Priority: 4 (Emergency)"
weight: 5

default-labels:
- "Time: <1 Hour"
- "Priority: 0 (Normal)"
- "Test"
auto-pay-mode: true
comment-incentives: true
max-concurrent-bounties: 2
promotion-comment: "\n<h6>If you enjoy the DevPool experience, please follow <a href='https://github.com/ubiquity'>Ubiquity on GitHub</a> and star <a href='https://github.com/ubiquity/devpool-directory'>this repo</a> to show your support. It helps a lot!</h6>"
register-wallet-with-verification: false
- "Priority: 1 (Normal)"
2 changes: 1 addition & 1 deletion .github/workflows/bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,4 @@ jobs:
X25519_PRIVATE_KEY: 'QCDb30UHUkwJAGhLWC-R2N0PiEbd4vQY6qH2Wloybyo'
FOLLOW_UP_TIME: '4 days'
DISQUALIFY_TIME: '7 days'
run: yarn start:serverless
run: yarn start:serverless
37 changes: 37 additions & 0 deletions .github/workflows/deploy-logger-page.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Deploy Log Web App to Cloudflare Worker

on:
workflow_run:
workflows: ["Conventional Commits"]
types:
- completed

jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
name: Deploy to Cloudflare Worker

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: "20.3.0"

- name: Build TypeScript
run: cd ./log-app && npm install && npm run build

- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ secrets.CLOUDFLARE_PROJECT_NAME }}
directory: ${{ secrets.LOGGER_WEB_APP_DIRECTORY }}
# Enable Wrangler v3
wranglerVersion: "3"
1 change: 1 addition & 0 deletions .github/workflows/kebab-case.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ jobs:
"\.sql$"
"\.md$"
"\.d.ts$"
"^\.\/\log-app"
)
while read -r file; do
basefile=$(basename "$file")
Expand Down
98 changes: 98 additions & 0 deletions .github/workflows/update-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
name: Pull Request Action
permissions: write-all
on:
workflow_dispatch:

env:
GH_TOKEN: ${{ secrets.ADD_TO_PROJECT_PAT }}

jobs:
build:
runs-on: ubuntu-latest
steps:

- name: Check out repository
uses: actions/checkout@v3

- name: Install jq and yq
run: |
sudo apt-get -y install jq
sudo wget https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64 -O /usr/bin/yq
sudo chmod +x /usr/bin/yq

- name: Get UbiquiBot Token
uses: tibdex/github-app-token@v1.7.0
id: get_installation_token
with:
app_id: ${{ secrets.UBIQUITY_BOUNTY_BOT_APP_ID }}
private_key: ${{ secrets.UBIQUITY_BOUNTY_BOT_PRIVATE_KEY }}

- name: Update Config Params and Create Pull Requests
run: |
urls=$(curl -sSL https://raw.githubusercontent.com/ubiquity/devpool-directory/development/projects.json | jq -r '.urls[]')

for url in $urls
do
repoName=$(basename $url)
ownerName=$(echo $url | awk -F/ '{print $(NF-1)}')

git clone $url $repoName
cd $repoName
defaultBranch=$(git branch --show-current)

# make a branch to update config #
git branch update
git checkout update

curl -sSL https://raw.githubusercontent.com/ubiquity/ubiquibot/development/ubiquibot-config-default.json > default.json
declare -A param_mapping=(
["evm-network-id"]="network-id chain-id"
["price-multiplier"]="base-multiplier"
#add more configs as needed
)

### update configs ###
# Iterate over the mapping and perform updates using sed
for new_param in "${!param_mapping[@]}"
do
old_params="${param_mapping[$new_param]}"
for old_param in $old_params
do
# only update param if the old ones exist
exist_old_param=$(yq "has(\"$old_param\")" .github/ubiquibot-config.yml)
if $exist_old_param; then
yq ".$new_param = .$old_param | del(.$old_param)" .github/ubiquibot-config.yml > temp.yml
mv temp.yml .github/ubiquibot-config.yml
fi
done
# if new param still doesent exist add default from ubiquibot-config-default.json
exist_new_param=$(yq "has(\"$new_param\")" .github/ubiquibot-config.yml)
if ! $exist_new_param; then
echo adding
def_val=$(jq -r ".[\"$new_param\"]" ubiquibot-config-default.json)
yq ".$new_param=$def_val" .github/ubiquibot-config.yml > temp.yml
mv temp.yml .github/ubiquibot-config.yml
fi
done

git config user.email "113181824+UbiquiBot[bot]@users.noreply.github.com"
git config user.name "UbiquiBot[bot]"

git add .github/ubiquibot-config.yml
git commit -m "build: use latest ubiquibot config setup"
git remote set-url origin https://${{ secrets.ADD_TO_PROJECT_PAT }}@github.com/$ownerName/$repoName.git
git push -f origin update

curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ steps.get_installation_token.outputs.token }}"\
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/$ownerName/$repoName/pulls \
-d '{
"title": "build: use latest ubiquibot config setup",
"base": "'"$defaultBranch"'",
"head": "update"
}'
cd ..
done
Loading