1 Star 0 Fork 32

杨一帆/vuepress-theme-hope

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.commitlintrc.cjs 764 Bytes
一键复制 编辑 原始数据 按行查看 历史
Mister-Hope 提交于 2022-12-05 03:08 +08:00 . chore: update deps
const fs = require("node:fs");
const path = require("path");
const { execSync } = require("child_process");
const packages = fs.readdirSync(path.resolve(__dirname, "packages"));
const scopeComplete = execSync("git status --porcelain || true")
.toString()
.trim()
.split("\n")
.find((r) => ~r.indexOf("M packages"))
?.replace(/\//g, "%%")
?.match(/packages%%((\w|-)*)/)?.[1];
/** @type {import('cz-git').UserConfig} */
module.exports = {
extends: ["@commitlint/config-conventional"],
rules: {
"scope-enum": [2, "always", ["demo", "release", ...packages]],
},
prompt: {
defaultScope: scopeComplete,
customScopesAlign: !scopeComplete ? "top" : "bottom",
allowCustomIssuePrefix: false,
allowEmptyIssuePrefix: false,
},
};
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
TypeScript
1
https://gitee.com/du229_yu/theme.git
[email protected]:du229_yu/theme.git
du229_yu
theme
vuepress-theme-hope
main

搜索帮助