Skip to content

Commit 97cae1f

Browse files
authored
Merge pull request #574 from enkryptcom/develop
Release: v2.0.0
2 parents 0aa10c5 + e798d89 commit 97cae1f

File tree

912 files changed

+59641
-32336
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

912 files changed

+59641
-32336
lines changed

.coderabbit.yaml

+104
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
language: en-US
2+
tone_instructions: ""
3+
early_access: false
4+
enable_free_tier: true
5+
reviews:
6+
profile: chill
7+
request_changes_workflow: true
8+
high_level_summary: true
9+
high_level_summary_placeholder: "@coderabbitai summary"
10+
auto_title_placeholder: "@coderabbitai"
11+
review_status: true
12+
commit_status: true
13+
poem: false
14+
collapse_walkthrough: false
15+
sequence_diagrams: true
16+
changed_files_summary: true
17+
labeling_instructions: []
18+
path_filters: []
19+
path_instructions: []
20+
abort_on_close: true
21+
auto_review:
22+
enabled: true
23+
auto_incremental_review: true
24+
ignore_title_keywords:
25+
- "!CR"
26+
drafts: false
27+
base_branches:
28+
- main
29+
- develop
30+
- devop/vite-migrate
31+
tools:
32+
shellcheck:
33+
enabled: true
34+
ruff:
35+
enabled: true
36+
markdownlint:
37+
enabled: true
38+
github-checks:
39+
enabled: true
40+
timeout_ms: 90000
41+
languagetool:
42+
enabled: true
43+
enabled_only: false
44+
level: default
45+
enabled_rules: []
46+
disabled_rules: []
47+
enabled_categories: []
48+
disabled_categories: []
49+
biome:
50+
enabled: true
51+
hadolint:
52+
enabled: true
53+
swiftlint:
54+
enabled: true
55+
phpstan:
56+
enabled: true
57+
level: default
58+
golangci-lint:
59+
enabled: true
60+
yamllint:
61+
enabled: true
62+
gitleaks:
63+
enabled: true
64+
checkov:
65+
enabled: true
66+
detekt:
67+
enabled: true
68+
eslint:
69+
enabled: true
70+
rubocop:
71+
enabled: true
72+
buf:
73+
enabled: true
74+
regal:
75+
enabled: true
76+
actionlint:
77+
enabled: true
78+
pmd:
79+
enabled: true
80+
cppcheck:
81+
enabled: true
82+
semgrep:
83+
enabled: true
84+
circleci:
85+
enabled: true
86+
ast-grep:
87+
packages: []
88+
rule_dirs: []
89+
util_dirs: []
90+
essential_rules: true
91+
chat:
92+
auto_reply: true
93+
knowledge_base:
94+
opt_out: false
95+
learnings:
96+
scope: auto
97+
issues:
98+
scope: auto
99+
jira:
100+
project_keys: []
101+
linear:
102+
team_keys: []
103+
pull_requests:
104+
scope: auto

.github/workflows/build-all.yml

+47-7
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,21 @@
11
name: Build all and Check VirusTotal
22

3-
on: [push]
3+
on: [pull_request]
44

55
jobs:
66
buildAll:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v4
1010

11+
- name: Comment Building
12+
uses: thollander/actions-comment-pull-request@v3
13+
with:
14+
message: |
15+
:monkey: Monkeys are building your code...
16+
comment-tag: pr_build_message
17+
mode: upsert
18+
1119
- name: setup env
1220
id: node-version
1321
run: |
@@ -19,7 +27,7 @@ jobs:
1927
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
2028

2129
- name: Cache yarn modules
22-
uses: actions/cache@v3
30+
uses: actions/cache@v4
2331
id: yarn-cache
2432
with:
2533
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
@@ -35,21 +43,53 @@ jobs:
3543
VIRUS_TOTAL_API_KEY: ${{secrets.VIRUS_TOTAL_API_KEY}}
3644
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
3745
run: |
46+
mkdir release-chrome
47+
mkdir release-firefox
3848
docker run --rm -v `pwd`:/home:rw --user "$(id -u):$(id -g)" enkrypt-build-container /bin/bash -c "yarn build:all"
3949
docker run --rm -v `pwd`:/home:rw --user "$(id -u):$(id -g)" enkrypt-build-container /bin/bash -c "cd packages/extension && yarn build:chrome && yarn zip"
50+
cp -r packages/extension/dist/* release-chrome
51+
rm release-chrome/release.zip
4052
FILE_SHA256=`sha256sum ./packages/extension/dist/release.zip | awk '{print $1}'`
4153
curl --request GET --url https://www.virustotal.com/api/v3/files/upload_url --header "x-apikey: $VIRUS_TOTAL_API_KEY"
4254
UPLOAD_URL=`curl --request GET --url https://www.virustotal.com/api/v3/files/upload_url --header "x-apikey: $VIRUS_TOTAL_API_KEY" | jq --raw-output '.data'`
4355
curl --request POST --url "$UPLOAD_URL" --header "x-apikey: $VIRUS_TOTAL_API_KEY" --header 'Accept: application/json' --header 'Content-Type: multipart/form-data' -F "file=@./packages/extension/dist/release.zip"
4456
VIRUS_TOTAL_URL_CHROME=https://www.virustotal.com/gui/file/$FILE_SHA256
4557
docker run --rm -v `pwd`:/home:rw --user "$(id -u):$(id -g)" enkrypt-build-container /bin/bash -c "cd packages/extension && yarn build:firefox && yarn zip"
58+
cp -r packages/extension/dist/* release-firefox
59+
rm release-firefox/release.zip
4660
FILE_SHA256=`sha256sum ./packages/extension/dist/release.zip | awk '{print $1}'`
4761
curl --request GET --url https://www.virustotal.com/api/v3/files/upload_url --header "x-apikey: $VIRUS_TOTAL_API_KEY"
4862
UPLOAD_URL=`curl --request GET --url https://www.virustotal.com/api/v3/files/upload_url --header "x-apikey: $VIRUS_TOTAL_API_KEY" | jq --raw-output '.data'`
4963
curl --request POST --url "$UPLOAD_URL" --header "x-apikey: $VIRUS_TOTAL_API_KEY" --header 'Accept: application/json' --header 'Content-Type: multipart/form-data' -F "file=@./packages/extension/dist/release.zip"
5064
VIRUS_TOTAL_URL_FIREFOX=https://www.virustotal.com/gui/file/$FILE_SHA256
51-
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST \
52-
-d "{\"body\": \"Virus total analysis <br/>chrome: <br/>$VIRUS_TOTAL_URL_CHROME<br/> \
53-
firefox: <br/> \
54-
$VIRUS_TOTAL_URL_FIREFOX\"}" \
55-
"https://api.github.com/repos/${GITHUB_REPOSITORY}/commits/${GITHUB_SHA}/comments"
65+
echo "VIRUS_TOTAL_URL_CHROME=$VIRUS_TOTAL_URL_CHROME" >> $GITHUB_ENV
66+
echo "VIRUS_TOTAL_URL_FIREFOX=$VIRUS_TOTAL_URL_FIREFOX" >> $GITHUB_ENV
67+
echo "SHORT_SHA=`echo $(cat $GITHUB_EVENT_PATH | jq -r .pull_request.head.sha) | cut -c1-8`" >> $GITHUB_ENV
68+
69+
- uses: actions/upload-artifact@v4
70+
id: artifact-upload-chrome
71+
with:
72+
name: enkrypt-chrome-${{ env.SHORT_SHA }}
73+
path: ./release-chrome
74+
retention-days: 3
75+
76+
- uses: actions/upload-artifact@v4
77+
id: artifact-upload-firefox
78+
with:
79+
name: enkrypt-firefox-${{ env.SHORT_SHA }}
80+
path: ./release-firefox
81+
retention-days: 3
82+
83+
- name: Comment PR
84+
uses: thollander/actions-comment-pull-request@v3
85+
with:
86+
message: |
87+
:briefcase: Build Files
88+
chrome: [enkrypt-chrome-${{ env.SHORT_SHA }}.zip](${{ steps.artifact-upload-chrome.outputs.artifact-url }})
89+
firefox: [enkrypt-firefox-${{ env.SHORT_SHA }}.zip](${{ steps.artifact-upload-firefox.outputs.artifact-url }})
90+
91+
:syringe: Virus total analysis
92+
chrome: [${{ env.SHORT_SHA }}](${{ env.VIRUS_TOTAL_URL_CHROME }})
93+
firefox: [${{ env.SHORT_SHA }}](${{ env.VIRUS_TOTAL_URL_FIREFOX }})
94+
comment-tag: pr_build_message
95+
mode: upsert

.github/workflows/release.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
2222

2323
- name: Cache yarn modules
24-
uses: actions/cache@v3
24+
uses: actions/cache@v4
2525
id: yarn-cache
2626
with:
2727
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}

.github/workflows/test-all.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v4
10-
- uses: actions/setup-node@v3
10+
- uses: actions/setup-node@v4
1111
with:
12-
node-version: "20"
12+
node-version: "22.10.0"
1313
cache: "yarn"
1414
- run: yarn install
1515
- run: yarn build:all

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -116,3 +116,6 @@ dist
116116
.DS_Store
117117

118118
.nova/
119+
120+
# IDE
121+
.history

.nvmrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
v22.11.0

.vscode/extensions.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"recommendations": [
3+
"Vue.volar",
34
"dbaeumer.vscode-eslint",
4-
"esbenp.prettier-vscode",
5-
"johnsoncodehk.volar"
5+
"esbenp.prettier-vscode"
66
]
77
}

.vscode/settings.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,9 @@
55
"changeProcessCWD": true
66
}
77
],
8-
"cSpell.words": ["enkrypt", "enkryptcom", "polkadot", "webextension"]
8+
"editor.codeActionsOnSave": {
9+
"source.fixAll": "explicit"
10+
},
11+
"editor.formatOnSave": true,
12+
"editor.defaultFormatter": "esbenp.prettier-vscode"
913
}

0 commit comments

Comments
 (0)