Files
gitea-jira-task-bot/data/mappings.json

100 lines
3.6 KiB
JSON
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
"comment": "映射表配置文件 - 配置此文件以启用特定仓库的同步功能。未在此文件中配置的仓库将不会进行同步。配置前,检查.env文件是否正确设置。此表已实现自动化配置通常不要手动编辑除非你知道自己在做什么。",
"guide": {
"description": "仓库手动配置指引",
"steps": [
"1.在环境变量(.env中设置好JIRA PROJECT ID和KEY",
"2.根据提示获得映射Gitea的变量是长啥样是啥样但是JIRA需要你去找各种ID",
"3.配置好启用的仓库,尽量不要用默认",
"4.映射配置不全时会使用defaultMappings中的默认值",
"5.SprintField通常是customfield_10105应该是Jira指定的不要随意更改"
],
"howToGetIds": {
"projectId": "访问 https://jira.langcore.cn/rest/api/2/project/{项目key} 的第一行 id 字段",
"priorities": "访问 https://jira.langcore.cn/rest/api/2/priority 查看 JSON 中的 id 和 name 字段。当前从highest到lowest分别是1到5",
"issueTypes": "访问 https://jira.langcore.cn/rest/api/2/issuetype 查看JSON中的id字段。当前bug是10004story是10001",
"sprints": "在已经加入了目标Sprint的任意Jira工单中访问 https://jira.langcore.cn/rest/api/2/issue/{工单Key},搜索 customfield_10105(或Sprint字段ID),查找[id=*,rapidViewId=*,name=...]格式中的id值",
"transitions": "访问 https://jira.langcore.cn/rest/api/2/issue/{工单Key}/transitions 查看JSON中的transitions数组。当前的三个id是 待办11 处理中21 完成31"
}
},
"repositories": {
"loren/SyncbotPlayground": {
"jira": {
"projectId": "10600",
"projectKey": "TASKBOT",
"sprintField": "customfield_10105"
},
"priorities": {
"优先级/最高": "1",
"优先级/高": "2",
"优先级/中": "3",
"优先级/低": "4",
"优先级/最低": "5"
},
"types": {
"类型/故事": "10100",
"类型/任务": "10100",
"类型/Bug": "10004"
},
"transitions": {
"close": "31",
"reopen": "21"
},
"sprints": {
"v1.0.0": 36
}
},
"langcore-develop-team/ltm": {
"jira": {
"projectId": "10001",
"projectKey": "LTM",
"sprintField": "customfield_10105"
},
"priorities": {
"优先级/紧急": "1",
"优先级/高": "2",
"优先级/中": "3",
"优先级/低": "4",
"优先级/极低": "5"
},
"types": {
"类型/新功能": "10002",
"类型/UI变更": "10002",
"类型/增强": "10002",
"类型/安全": "10002",
"类型/文档": "10002",
"类型/测试": "10002",
"类型/需求": "10002",
"类型/Bug": "10004"
},
"transitions": {},
"sprints": {
"v1.16.0": 39,
"v1.15.0": 36,
"v1.14.0": 35
}
}
},
"defaultMappings": {
"comment": "默认映射配置 - 当仓库未配置特定映射时使用这些默认值。注意通常不要使用默认Jira项目配置建议每个仓库都明确配置因为这会导致工单创建到同一个项目",
"priorities": {
"testhighest": "1",
"testhigh": "2",
"testmid": "3",
"testlow": "4",
"testlowest": "5"
},
"types": {
"testbug": "10004",
"teststory": "10001"
},
"sprints": {
"v1.0.0": 37
},
"transitions": {
"close": "31",
"reopen": "21",
"in_progress": "21"
}
}
}