Skip to content

Commit

Permalink
add 1min wait
Browse files Browse the repository at this point in the history
  • Loading branch information
capaj committed Jan 30, 2025
1 parent 9a850b6 commit bbc8821
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 16 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/publish-on-chrome-webstore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,9 @@ jobs:
envFile: './.github/workflows/constants.env'
expand: true

- name: Wait for CRX to be available
run: sleep 60 # Wait 1 minute for the CRX to be processed

- name: Download published crx file
id: gWebStoreDownloadCrx
uses: cardinalby/webext-buildtools-chrome-webstore-download-crx-action@v1
Expand Down
24 changes: 8 additions & 16 deletions web-extension/scripts/release.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,19 @@
import fs from 'fs-extra'
import { exec } from 'child_process'
import { execSync } from 'child_process'
import type PkgType from '../package.json'
import { dir } from './generateExtensionManifest'

async function pushNewTag() {
const pkg = (await fs.readJSON(dir('package.json'))) as typeof PkgType
const { version } = pkg

const tagName = `v${version}-extension`
exec(
`git commit -m "Release version ${version}" && git tag -a ${tagName} -m "version ${version}" && git push origin`,
(error, stdout, stderr) => {
if (error) {
console.error(`Failed to commit, create, or push git tag: ${error}`)
return
}
if (stderr) {
console.error(`stderr: ${stderr}`)
return
}
console.log(stdout)
}
)

execSync(`git commit -m "Release version ${version}"`)
execSync(`git tag -a ${tagName} -m "version ${version}"`)
execSync('git push origin')
execSync(`git push origin ${tagName}`)

console.log(`Successfully created and pushed tag ${tagName}`)
}

pushNewTag()

0 comments on commit bbc8821

Please sign in to comment.