更改 build 方案

This commit is contained in:
fofolee 2022-04-16 13:10:32 +08:00
parent 6a2254f68f
commit e5af0ae63a
22 changed files with 219 additions and 199 deletions

View File

@ -1,5 +1,3 @@
# 快捷命令 V3.0.0
[![GitHub stars](https://img.shields.io/github/stars/fofolee/uTools-quickcommand?style=flat-square)](https://github.com/fofolee/uTools-quickcommand/stargazers) [![GitHub forks](https://img.shields.io/github/forks/fofolee/uTools-quickcommand?style=flat-square)](https://github.com/fofolee/uTools-quickcommand/network/members) [![GitHub license](https://img.shields.io/github/license/fofolee/uTools-quickcommand?style=flat-square)](https://github.com/fofolee/uTools-quickcommand/blob/master/LICENSE) [![version](https://img.shields.io/badge/dynamic/json?color=f58142&label=version&query=%24.version&url=https%3A%2F%2Fraw.githubusercontent.com%2Ffofolee%2FuTools-quickcommand%2Fmaster%2Fsrc%2Fplugin.json&style=flat-square)](https://github.com/fofolee/uTools-quickcommand/blob/master/src/helps/CHANGELOG.md) [![猿料](https://img.shields.io/badge/%E7%8C%BF%E6%96%99-%2Fd%2F424-red?style=flat-square)](https://yuanliao.info/d/424) [![评论](https://img.shields.io/badge/dynamic/json?color=%2350e3c2&label=%E8%AF%84%E8%AE%BA&query=%24.data.attributes.commentCount&url=https%3A%2F%2Fyuanliao.info%2Fapi%2Fdiscussions%2F424&style=flat-square)](https://yuanliao.info/d/424)
@ -7,6 +5,7 @@
## 简介
- 核心功能
- 快速执行命令:如打开文件夹、软件、网址等
- 快速运行脚本如批处理、shell、python 等
@ -14,6 +13,7 @@
- 无需编写插件:实现需要使用 utools 的 api 或者带 UI 界面的功能
- 其他特色
- 内置了执行 shell 命令、文本处理、文本替换、网址二维码等实用命令
- 支持在插件内下载别人分享的命令
@ -22,7 +22,6 @@
[目前实现的功能列表 >>](https://yuanliao.info/d/2962)
## 功能
### 1.内置命令
@ -157,18 +156,19 @@
![UaNvPx.png](https://s1.ax1x.com/2020/07/14/UaNvPx.png)
## 编译安装
```sh
npm i -g @quasar/cli
cd uTools-quickcommand
npm i && cd plugin && npm i && cd ..
# Mac && Linux
./build.sh
# Windows
build.bat
# 调试
quasar dev
# 编译
quasar build
```
然后在开发者工具里面,选择`uTools-quickcommand/dist/spa/plugin.json`后打包
## 插件发布页
https://yuanliao.info/d/424
## 关键字

View File

@ -1,2 +0,0 @@
@echo off
quasar build && powershell -Command "Copy-Item -Recurse -Force plugin/* dist/spa/" && echo Done.

View File

@ -1,2 +0,0 @@
#!/bin/sh
quasar build && cp -r plugin/* dist/spa/ && echo Done.

1
package-lock.json generated
View File

@ -23,6 +23,7 @@
"devDependencies": {
"@babel/eslint-parser": "^7.13.14",
"@quasar/app-webpack": "^3.0.0",
"copy-webpack-plugin": "^10.2.4",
"eslint": "^8.10.0",
"eslint-config-prettier": "^8.1.0",
"eslint-plugin-vue": "^8.5.0",

View File

@ -26,6 +26,7 @@
"devDependencies": {
"@babel/eslint-parser": "^7.13.14",
"@quasar/app-webpack": "^3.0.0",
"copy-webpack-plugin": "^10.2.4",
"eslint": "^8.10.0",
"eslint-config-prettier": "^8.1.0",
"eslint-plugin-vue": "^8.5.0",

View File

@ -11,8 +11,11 @@
const ESLintPlugin = require('eslint-webpack-plugin')
const MonacoEditorPlugin = require("monaco-editor-webpack-plugin");
const CopyPlugin = require("copy-webpack-plugin");
const { configure } = require('quasar/wrappers');
const {
configure
} = require('quasar/wrappers');
module.exports = configure(function(ctx) {
return {
@ -74,9 +77,21 @@ module.exports = configure(function (ctx) {
chainWebpack(chain) {
chain.plugin('eslint-webpack-plugin')
.use(ESLintPlugin, [{ extensions: [ 'js', 'vue' ] }])
.use(ESLintPlugin, [{
extensions: ['js', 'vue']
}])
chain.plugin("monaco-editor-webpack-plugin")
.use(MonacoEditorPlugin);
chain.plugin("copy-webpack-plugin")
.use(CopyPlugin, [{
patterns: [{
from: './plugin/',
to: ".",
info: {
minimized: true
},
}],
}]);
},
},
@ -127,7 +142,9 @@ module.exports = configure(function (ctx) {
chainWebpackWebserver(chain) {
chain.plugin('eslint-webpack-plugin')
.use(ESLintPlugin, [{ extensions: [ 'js' ] }])
.use(ESLintPlugin, [{
extensions: ['js']
}])
},
@ -147,7 +164,9 @@ module.exports = configure(function (ctx) {
chainWebpackCustomSW(chain) {
chain.plugin('eslint-webpack-plugin')
.use(ESLintPlugin, [{ extensions: [ 'js' ] }])
.use(ESLintPlugin, [{
extensions: ['js']
}])
},
@ -159,8 +178,7 @@ module.exports = configure(function (ctx) {
orientation: 'portrait',
background_color: '#ffffff',
theme_color: '#027be3',
icons: [
{
icons: [{
src: 'icons/icon-128x128.png',
sizes: '128x128',
type: 'image/png'
@ -226,14 +244,18 @@ module.exports = configure(function (ctx) {
chainWebpackMain(chain) {
chain.plugin('eslint-webpack-plugin')
.use(ESLintPlugin, [{ extensions: [ 'js' ] }])
.use(ESLintPlugin, [{
extensions: ['js']
}])
},
chainWebpackPreload(chain) {
chain.plugin('eslint-webpack-plugin')
.use(ESLintPlugin, [{ extensions: [ 'js' ] }])
.use(ESLintPlugin, [{
extensions: ['js']
}])
},
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 826 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB