Skip to content

fix: map query string bug #554

fix: map query string bug

fix: map query string bug #554

# This is a basic workflow to help you get started with Actions
name: CI
# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches: [ main ]
pull_request:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains jobs "bump-version", "build" and "artifact"
bump-version:
if: github.event_name != 'pull_request'
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- name: Bump version and push tag
uses: anothrNick/github-tag-action@1.36.0
id: version-bump
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DEFAULT_BUMP: patch
WITH_V: true
- name: set up env new_version
run: echo "NEW_VERSION=$(echo ${{ steps.version-bump.outputs.new_tag }} | cut -c2-20)" >> $GITHUB_ENV
outputs:
new-version: ${{ env.NEW_VERSION }}
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
# Install project dependencies
- name: Install dependencies
run: npm ci
- name: Typescript check
run: npx tsc --noEmit
artifact:
needs: [bump-version, build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '16'
- name: Install dependencies
run: npm ci
# - name: Pack extension for Firefox
# run: npm run pack
- name: Pack extension for Chrome
run: npm run pack:test
- name: Override manifest with new version
if: github.event_name != 'pull_request'
run: |
echo 'New version ${{ needs.bump-version.outputs.new-version }}'
mv build-chrome/manifest.json build-chrome/temp.json && jq '.version = "${{needs.bump-version.outputs.new-version}}"' build-chrome/temp.json > build-chrome/manifest.json && rm build-chrome/temp.json
- name: Save as artifact
uses: actions/upload-artifact@v4
with:
name: extension
path: |
build-chrome