aliuq / degit-webext

Fast copy a Degit command path in github repository pages

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Degit Webext

firefox firefox chrome chrome

A web extension for Degit, it generates a button and add a shortcut key to fast copy a Degit command path in github repository page, support chrome and firefox now.

xuanfa

About

Forked from vitesse-webext, and modified to fit my needs. chrome manifest v3 is different from v2. the most important thing is that v2 is disabled loading script from remote server, so HMR in development is not supported. another thing is that firefox doesn't support manifest v3 yet.

Development

Because of the manifest version different between chrome(mv3) and firefox(mv2), You have to use different way to develope and build the extension. it has some default configuration, auto open devtools, start maximize window and start urls.

For chrome: ensure chromium is installed, and then run the following command:

pnpm dev:chromium
pnpm start:chromium

# Build
pnpm build:chromium
pnpm run pack

For firefox: ensure firefox is installed, and added to the environment variable PATH. if not, you have to point to the firefox executable file. another thing is that firefox has a firefoxProfile field in package.json, you can delete this line or provide a profile name to start firefox with a profile. type about:profiles in the firefox address bar, you can find your all profiles. then run the following command:

pnpm dev:firefox
pnpm start:firefox

# Build
pnpm build:firefox
pnpm run pack

For other browsers based on Google kernel, you can through setting --chromium-binary value to develope and debug the extension. e.g.

web-ext run -t chromium --chromium-binary C:/software/XXX/XXX.exe

License

MIT

About

Fast copy a Degit command path in github repository pages

License:MIT License


Languages

Language:TypeScript 79.2%Language:Vue 18.0%Language:CSS 1.8%Language:HTML 0.9%