Skip to content

Commit 3effc1b

Browse files
authored
Merge pull request #1 from kapildev421/main
Initial Release
2 parents 9eb1c93 + 05f83d4 commit 3effc1b

491 files changed

Lines changed: 47411 additions & 1 deletion

File tree

Some content is hidden

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

.github/pull_request_template.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
[Ticket ID](url)
2+
3+
### Requirements
4+
<!-- List the requirements for this PR -->
5+
6+
### Changes
7+
<!-- Summarize the changes introduced in this PR -->
8+
9+
### Testing Notes
10+
<!-- How did you test it? -->
11+
12+
### Things reviewers should pay attention to
13+
<!-- Highlight anything specific you want reviewers to focus on -->
14+
15+
### Screenshots/Recordings
16+
<!-- Add screenshots or screen recordings if applicable -->
17+
18+
### dependencies
19+
<!-- List any dependent work items or PRs -->
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
name: Build Browser Extension
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- dev
8+
9+
10+
permissions:
11+
contents: write
12+
13+
jobs:
14+
build:
15+
runs-on: macos-latest
16+
outputs:
17+
VERSION: ${{ steps.meta.outputs.VERSION }}
18+
TAG: ${{ steps.meta.outputs.TAG }}
19+
20+
steps:
21+
- name: Checkout
22+
uses: actions/checkout@v4
23+
with:
24+
submodules: true
25+
token: ${{ secrets.PAT_TOKEN }}
26+
27+
- name: Read & validate version
28+
id: meta
29+
run: |
30+
set -euo pipefail
31+
VERSION=$(jq -r '.version' package.json)
32+
echo "VERSION=$VERSION"
33+
if [[ ! "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
34+
echo "❌ Error: package.json version ('$VERSION') is not semantic versioning (MAJOR.MINOR.PATCH)."
35+
exit 1
36+
fi
37+
TAG="v$VERSION"
38+
echo "TAG=$TAG"
39+
echo "VERSION=$VERSION" >> "$GITHUB_OUTPUT"
40+
echo "TAG=$TAG" >> "$GITHUB_OUTPUT"
41+
42+
- name: Setup Node
43+
uses: actions/setup-node@v4
44+
with:
45+
node-version: 22
46+
cache: npm
47+
registry-url: https://npm.pkg.github.com
48+
scope: '@tetherto'
49+
50+
- name: Install worker dependencies
51+
run: |
52+
git config --global url."https://github.com/".insteadOf git@github.com:
53+
git config --global url."https://".insteadOf ssh://
54+
git config --global url."https://${{ secrets.PAT_TOKEN }}:x-oauth-basic@github.com/".insteadOf "https://github.com/"
55+
npm install --install-links --legacy-peer-deps
56+
env:
57+
NODE_AUTH_TOKEN: ${{ secrets.PAT_TOKEN }}
58+
59+
- name: Compile i18n catalogs (Lingui)
60+
run: npm run lingui:compile
61+
62+
- name: Build extension (Vite)
63+
run: npm run build
64+
env:
65+
VITE_SLACK_WEBHOOK_URL_PATH: ${{ secrets.SLACK_WEBHOOK_URL_PATH }}
66+
VITE_GOOGLE_FORM_KEY: ${{ secrets.GOOGLE_FORM_KEY }}
67+
VITE_GOOGLE_FORM_MAPPING_TIMESTAMP: ${{ secrets.GOOGLE_FORM_MAPPING_TIMESTAMP }}
68+
VITE_GOOGLE_FORM_MAPPING_TOPIC: ${{ secrets.GOOGLE_FORM_MAPPING_TOPIC }}
69+
VITE_GOOGLE_FORM_MAPPING_APP: ${{ secrets.GOOGLE_FORM_MAPPING_APP }}
70+
VITE_GOOGLE_FORM_MAPPING_OPERATING_SYSTEM: ${{ secrets.GOOGLE_FORM_MAPPING_OPERATING_SYSTEM }}
71+
VITE_GOOGLE_FORM_MAPPING_DEVICE_MODEL: ${{ secrets.GOOGLE_FORM_MAPPING_DEVICE_MODEL }}
72+
VITE_GOOGLE_FORM_MAPPING_MESSAGE: ${{ secrets.GOOGLE_FORM_MAPPING_MESSAGE }}
73+
VITE_GOOGLE_FORM_MAPPING_APP_VERSION: ${{ secrets.GOOGLE_FORM_MAPPING_APP_VERSION }}
74+
VITE_TEST_SLACK_WEBHOOK_URL_PATH: ${{ secrets.TEST_SLACK_WEBHOOK_URL_PATH }}
75+
VITE_TEST_GOOGLE_FORM_KEY: ${{ secrets.TEST_GOOGLE_FORM_KEY }}
76+
VITE_TEST_GOOGLE_FORM_MAPPING_TIMESTAMP: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_TIMESTAMP }}
77+
VITE_TEST_GOOGLE_FORM_MAPPING_TOPIC: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_TOPIC }}
78+
VITE_TEST_GOOGLE_FORM_MAPPING_APP: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_APP }}
79+
VITE_TEST_GOOGLE_FORM_MAPPING_OPERATING_SYSTEM: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_OPERATING_SYSTEM }}
80+
VITE_TEST_GOOGLE_FORM_MAPPING_DEVICE_MODEL: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_DEVICE_MODEL }}
81+
VITE_TEST_GOOGLE_FORM_MAPPING_MESSAGE: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_MESSAGE }}
82+
VITE_TEST_GOOGLE_FORM_MAPPING_APP_VERSION: ${{ secrets.TEST_GOOGLE_FORM_MAPPING_APP_VERSION }}
83+
84+
- name: Package Chrome ZIP
85+
run: |
86+
set -euo pipefail
87+
cd dist
88+
zip -r "../PearPass-Browser-${{ steps.meta.outputs.TAG }}.zip" .
89+
90+
- name: Upload artifact
91+
uses: actions/upload-artifact@v4
92+
with:
93+
name: PearPass-Browser-${{ steps.meta.outputs.TAG }}.zip
94+
path: PearPass-Browser-${{ steps.meta.outputs.TAG }}.zip
95+
96+
release:
97+
runs-on: macos-latest
98+
needs: [build]
99+
if: ${{ github.ref == 'refs/heads/main' }}
100+
steps:
101+
- name: Download artifacts
102+
uses: actions/download-artifact@v5
103+
with:
104+
path: artifacts/
105+
106+
- name: Create GitHub Release
107+
uses: softprops/action-gh-release@v2
108+
with:
109+
tag_name: ${{ needs.build.outputs.TAG }}
110+
name: PearPass-Browser-${{ needs.build.outputs.TAG }}
111+
draft: false
112+
generate_release_notes: true
113+
files: artifacts/**/*.zip

.gitignore

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
dist
12+
dist-ssr
13+
*.local
14+
15+
# Editor directories and files
16+
.vscode/*
17+
!.vscode/extensions.json
18+
.idea
19+
.DS_Store
20+
*.suo
21+
*.ntvs*
22+
*.njsproj
23+
*.sln
24+
*.sw?
25+
26+
.yalc
27+
yalc.lock
28+
29+
.env

.gitmodules

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
[submodule "packages/pear-apps-lib-feedback"]
2+
path = packages/pear-apps-lib-feedback
3+
url = ../pear-apps-lib-feedback.git
4+
branch = main
5+
[submodule "packages/pear-apps-lib-ui-react-hooks"]
6+
path = packages/pear-apps-lib-ui-react-hooks
7+
url = ../pear-apps-lib-ui-react-hooks.git
8+
branch = main
9+
[submodule "packages/pear-apps-utils-avatar-initials"]
10+
path = packages/pear-apps-utils-avatar-initials
11+
url = ../pear-apps-utils-avatar-initials.git
12+
branch = main
13+
[submodule "packages/pear-apps-utils-date"]
14+
path = packages/pear-apps-utils-date
15+
url = ../pear-apps-utils-date.git
16+
branch = main
17+
[submodule "packages/pear-apps-utils-pattern-search"]
18+
path = packages/pear-apps-utils-pattern-search
19+
url = ../pear-apps-utils-pattern-search.git
20+
branch = main
21+
[submodule "packages/pear-apps-utils-qr"]
22+
path = packages/pear-apps-utils-qr
23+
url = ../pear-apps-utils-qr.git
24+
branch = main
25+
[submodule "packages/pear-apps-utils-validator"]
26+
path = packages/pear-apps-utils-validator
27+
url = ../pear-apps-utils-validator.git
28+
branch = main
29+
[submodule "packages/pearpass-lib-constants"]
30+
path = packages/pearpass-lib-constants
31+
url = ../pearpass-lib-constants.git
32+
branch = main
33+
[submodule "packages/pearpass-lib-ui-theme-provider"]
34+
path = packages/pearpass-lib-ui-theme-provider
35+
url = ../pearpass-lib-ui-theme-provider.git
36+
branch = main
37+
[submodule "packages/pearpass-lib-vault"]
38+
path = packages/pearpass-lib-vault
39+
url = ../pearpass-lib-vault.git
40+
branch = main
41+
[submodule "packages/pearpass-utils-password-check"]
42+
path = packages/pearpass-utils-password-check
43+
url = ../pearpass-utils-password-check.git
44+
branch = main
45+
[submodule "packages/pear-apps-utils-generate-unique-id"]
46+
path = packages/pear-apps-utils-generate-unique-id
47+
url = ../pear-apps-utils-generate-unique-id.git
48+
branch = main
49+
[submodule "packages/pearpass-utils-password-generator"]
50+
path = packages/pearpass-utils-password-generator
51+
url = ../pearpass-utils-password-generator.git
52+
branch = main
53+
[submodule "packages/tether-dev-docs"]
54+
path = packages/tether-dev-docs
55+
url = ../tether-dev-docs.git
56+
branch = main

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
22.12.0

CONTRIBUTING.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Contributing to PearPass
2+
3+
The source is open to use as per the [LICENSE](./LICENSE).
4+
5+
Be aware that **any pull-request or issue may be closed without explanation**.
6+
7+
## Issues
8+
9+
- Feature requests are welcome.
10+
- For bug reports, please provide a failing test case or steps to reproduce.
11+
12+
## Pull Request
13+
14+
Newer contributors are encouraged to start small and simple. Tests - both failing and passing - are very helpful.
15+
16+
- Keep pull requests focused on a single feature or bug fix
17+
- Provide a clear description of changes
18+
- Ensure code passes linting: `npm run lint`
19+
- Ensure tests are passing: `npm test`
20+
- except, of course, any added failing tests
21+
22+
23+
## License
24+
25+
By contributing, you agree that your contributions will be licensed under the project [LICENSE](./LICENSE).

0 commit comments

Comments
 (0)