From 6bb4b61374c72816443d9e0048c0aab942996cfe Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 20:56:06 +0800 Subject: [PATCH 1/6] Remove not use file --- .browserslistrc | 4 ---- 1 file changed, 4 deletions(-) delete mode 100644 .browserslistrc diff --git a/.browserslistrc b/.browserslistrc deleted file mode 100644 index dc3bc09..0000000 --- a/.browserslistrc +++ /dev/null @@ -1,4 +0,0 @@ -> 1% -last 2 versions -not dead -not ie 11 From 1072be92685889fc739a760d112b57be09db8d75 Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 21:01:12 +0800 Subject: [PATCH 2/6] Move the Github Action built by Dockr to the. github folder --- .gitlab-ci.yml => .github/workflows/.gitlab-ci.yml | 0 .gitpod.yml => .github/workflows/.gitpod.yml | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename .gitlab-ci.yml => .github/workflows/.gitlab-ci.yml (100%) rename .gitpod.yml => .github/workflows/.gitpod.yml (85%) diff --git a/.gitlab-ci.yml b/.github/workflows/.gitlab-ci.yml similarity index 100% rename from .gitlab-ci.yml rename to .github/workflows/.gitlab-ci.yml diff --git a/.gitpod.yml b/.github/workflows/.gitpod.yml similarity index 85% rename from .gitpod.yml rename to .github/workflows/.gitpod.yml index 866381f..88f987c 100644 --- a/.gitpod.yml +++ b/.github/workflows/.gitpod.yml @@ -1,5 +1,5 @@ ports: - - port: 3344 + - port: 3000 onOpen: open-preview tasks: - init: pnpm install From b5f93af16dcffb6fcfc076ed813ee18f27b0d237 Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 21:01:26 +0800 Subject: [PATCH 3/6] remove upload url --- .env.production | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.env.production b/.env.production index 4aeeb97..5a62db0 100644 --- a/.env.production +++ b/.env.production @@ -9,12 +9,6 @@ VITE_BUILD_COMPRESS = 'none' # Delete console VITE_DROP_CONSOLE = false -# Basic interface address SPA -VITE_GLOB_API_URL= - -# File upload address, optional -VITE_GLOB_UPLOAD_URL=/fms-api/upload - # Interface prefix VITE_GLOB_API_URL_PREFIX= From 12ea85c004eb8b900a99f5a082a8f4082a605cf4 Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 21:01:39 +0800 Subject: [PATCH 4/6] delete not use file --- .commitlintrc.js | 107 ----------------------------------------------- .dockerignore | 7 ---- 2 files changed, 114 deletions(-) delete mode 100644 .commitlintrc.js delete mode 100644 .dockerignore diff --git a/.commitlintrc.js b/.commitlintrc.js deleted file mode 100644 index 151ead3..0000000 --- a/.commitlintrc.js +++ /dev/null @@ -1,107 +0,0 @@ -const fs = require('fs'); -const path = require('path'); -const { execSync } = require('child_process'); - -const scopes = fs - .readdirSync(path.resolve(__dirname, 'src'), { withFileTypes: true }) - .filter((dirent) => dirent.isDirectory()) - .map((dirent) => dirent.name.replace(/s$/, '')); - -// precomputed scope -const scopeComplete = execSync('git status --porcelain || true') - .toString() - .trim() - .split('\n') - .find((r) => ~r.indexOf('M src')) - ?.replace(/(\/)/g, '%%') - ?.match(/src%%((\w|-)*)/)?.[1] - ?.replace(/s$/, ''); - -/** @type {import('cz-git').UserConfig} */ -module.exports = { - ignores: [(commit) => commit.includes('init')], - extends: ['@commitlint/config-conventional'], - rules: { - 'body-leading-blank': [2, 'always'], - 'footer-leading-blank': [1, 'always'], - 'header-max-length': [2, 'always', 108], - 'subject-empty': [2, 'never'], - 'type-empty': [2, 'never'], - 'subject-case': [0], - 'type-enum': [ - 2, - 'always', - [ - 'feat', - 'fix', - 'perf', - 'style', - 'docs', - 'test', - 'refactor', - 'build', - 'ci', - 'chore', - 'revert', - 'wip', - 'workflow', - 'types', - 'release', - ], - ], - }, - prompt: { - /** @use `yarn commit :f` */ - alias: { - f: 'docs: fix typos', - r: 'docs: update README', - s: 'style: update code format', - b: 'build: bump dependencies', - c: 'chore: update config', - }, - customScopesAlign: !scopeComplete ? 'top' : 'bottom', - defaultScope: scopeComplete, - scopes: [...scopes, 'mock'], - allowEmptyIssuePrefixs: false, - allowCustomIssuePrefixs: false, - - // English - typesAppend: [ - { value: 'wip', name: 'wip: work in process' }, - { value: 'workflow', name: 'workflow: workflow improvements' }, - { value: 'types', name: 'types: type definition file changes' }, - ], - - // 中英文对照版 - // messages: { - // type: '选择你要提交的类型 :', - // scope: '选择一个提交范围 (可选):', - // customScope: '请输入自定义的提交范围 :', - // subject: '填写简短精炼的变更描述 :\n', - // body: '填写更加详细的变更描述 (可选)。使用 "|" 换行 :\n', - // breaking: '列举非兼容性重大的变更 (可选)。使用 "|" 换行 :\n', - // footerPrefixsSelect: '选择关联issue前缀 (可选):', - // customFooterPrefixs: '输入自定义issue前缀 :', - // footer: '列举关联issue (可选) 例如: #31, #I3244 :\n', - // confirmCommit: '是否提交或修改commit ?', - // }, - // types: [ - // { value: 'feat', name: 'feat: 新增功能' }, - // { value: 'fix', name: 'fix: 修复缺陷' }, - // { value: 'docs', name: 'docs: 文档变更' }, - // { value: 'style', name: 'style: 代码格式' }, - // { value: 'refactor', name: 'refactor: 代码重构' }, - // { value: 'perf', name: 'perf: 性能优化' }, - // { value: 'test', name: 'test: 添加疏漏测试或已有测试改动' }, - // { value: 'build', name: 'build: 构建流程、外部依赖变更 (如升级 npm 包、修改打包配置等)' }, - // { value: 'ci', name: 'ci: 修改 CI 配置、脚本' }, - // { value: 'revert', name: 'revert: 回滚 commit' }, - // { value: 'chore', name: 'chore: 对构建过程或辅助工具和库的更改 (不影响源文件、测试用例)' }, - // { value: 'wip', name: 'wip: 正在开发中' }, - // { value: 'workflow', name: 'workflow: 工作流程改进' }, - // { value: 'types', name: 'types: 类型定义文件修改' }, - // ], - // emptyScopesAlias: 'empty: 不填写', - // customScopesAlias: 'custom: 自定义', - }, -}; diff --git a/.dockerignore b/.dockerignore deleted file mode 100644 index b6c375e..0000000 --- a/.dockerignore +++ /dev/null @@ -1,7 +0,0 @@ -node_modules/ -.husky/ -build/ -public/ -src/ -tests/ -types/ \ No newline at end of file From 3fde00ff901207f3cb5d5b0b179d9f3783294c6e Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 21:05:21 +0800 Subject: [PATCH 5/6] Move to Docker File Directory Structure --- Dockerfile | 8 -------- docker/Dockerfile | 8 ++++++++ Makefile => docker/Makefile | 0 3 files changed, 8 insertions(+), 8 deletions(-) delete mode 100644 Dockerfile create mode 100644 docker/Dockerfile rename Makefile => docker/Makefile (100%) diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index ae44331..0000000 --- a/Dockerfile +++ /dev/null @@ -1,8 +0,0 @@ -FROM nginx:1.23.4-alpine - -COPY dist/ /usr/share/nginx/html/ -COPY deploy/default.conf /etc/nginx/conf.d/ - -LABEL MAINTAINER="RyanSU@yuansu.china.work@gmail.com" - -EXPOSE 80 diff --git a/docker/Dockerfile b/docker/Dockerfile new file mode 100644 index 0000000..2fc40ea --- /dev/null +++ b/docker/Dockerfile @@ -0,0 +1,8 @@ +FROM nginx:1.23.4-alpine + +COPY dist/ /usr/share/nginx/html/ +COPY ../deploy/default.conf /etc/nginx/conf.d/ + +LABEL MAINTAINER="team@wansenai.com" + +EXPOSE 80 diff --git a/Makefile b/docker/Makefile similarity index 100% rename from Makefile rename to docker/Makefile From f487626d75ead9d44e3ae5ed469f2b05a6042cb5 Mon Sep 17 00:00:00 2001 From: jameszow Date: Fri, 22 Sep 2023 21:05:42 +0800 Subject: [PATCH 6/6] delete --- .stylelintignore | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 .stylelintignore diff --git a/.stylelintignore b/.stylelintignore deleted file mode 100644 index 6cd69e0..0000000 --- a/.stylelintignore +++ /dev/null @@ -1,2 +0,0 @@ -dist -public