diff --git a/.github/workflows/submit.yml b/.github/workflows/submit.yml index 3f20013..8f13673 100644 --- a/.github/workflows/submit.yml +++ b/.github/workflows/submit.yml @@ -1,32 +1,37 @@ name: 'Submit to Web Store' + +#Documentation for secrets: https://github.com/PlasmoHQ/bms/blob/main/tokens.md +#There is already an existing google cloud console project that the chrome keys were generated from +#The secrets are linked to my gotyhill@gmail.com email since it is a developer account and has access on both chrome and firefox + on: workflow_dispatch: +#This could run on each push to main but it would only work like once a day for chrome +#Chrome won't allow submitting another package when one is in review jobs: - build: + main: + name: Build and publish runs-on: ubuntu-latest + steps: - - uses: actions/checkout@v3 - - name: Cache pnpm modules - uses: actions/cache@v3 - with: - path: ~/.pnpm-store - key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }} - restore-keys: | - ${{ runner.os }}- - - uses: pnpm/action-setup@v2.2.4 - with: - version: latest - run_install: true - - name: Use Node.js 16.x - uses: actions/setup-node@v3.4.1 + - name: Check out Git repository + uses: actions/checkout@v3 + + - name: Set up Node.js + uses: actions/setup-node@v3 with: - node-version: 16.x - cache: 'pnpm' - - name: Build and zip extension artifact - run: pnpm package - - name: Browser Platform Publish + node-version: 18 + + - name: Install packages + run: npm ci + + - name: Build and package extension + run: npm run build:chrome && npm run build:firefox + + - name: Publish extension uses: PlasmoHQ/bpp@v3 with: keys: ${{ secrets.SUBMIT_KEYS }} - artifact: build/chrome-mv3-prod.zip + chrome-file: build/chrome-mv3-prod.zip + firefox-file: build/firefox-mv3-prod.zip diff --git a/package.json b/package.json index 1edf93f..54f0bcc 100644 --- a/package.json +++ b/package.json @@ -1,15 +1,15 @@ { "name": "sk.edge", "displayName": "sk.edge", - "version": "0.0.1", + "version": "0.0.6", "description": "your registration assistant by students, for students", "author": "Nebula Labs", "packageManager": "npm@8.19.2", "scripts": { - "dev": "plasmo dev", + "dev:chrome": "plasmo dev --target=chrome-mv3", "dev:firefox": "plasmo dev --target=firefox-mv3", - "build": "plasmo build", - "package": "plasmo package", + "build:chrome": "plasmo build --target=chrome-mv3 --zip", + "build:firefox": "plasmo build --target=firefox-mv3 --zip", "format": "prettier --write .", "format:check": "prettier --check .", "lint": "next lint --fix",