mirror of
https://github.com/go-gitea/gitea.git
synced 2025-02-02 15:09:33 -05:00
yaml support
This commit is contained in:
parent
104e4c517b
commit
182aed4bfb
@ -18,6 +18,7 @@ type Label struct {
|
|||||||
Color string `yaml:"color"`
|
Color string `yaml:"color"`
|
||||||
Description string `yaml:"description,omitempty"`
|
Description string `yaml:"description,omitempty"`
|
||||||
Exclusive bool `yaml:"exclusive,omitempty"`
|
Exclusive bool `yaml:"exclusive,omitempty"`
|
||||||
|
ExclusiveOrder int `yaml:"exclusive_order,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// NormalizeColor normalizes a color string to a 6-character hex code
|
// NormalizeColor normalizes a color string to a 6-character hex code
|
||||||
|
@ -156,6 +156,7 @@ func InitializeLabels(ctx context.Context, id int64, labelTemplate string, isOrg
|
|||||||
labels[i] = &issues_model.Label{
|
labels[i] = &issues_model.Label{
|
||||||
Name: list[i].Name,
|
Name: list[i].Name,
|
||||||
Exclusive: list[i].Exclusive,
|
Exclusive: list[i].Exclusive,
|
||||||
|
ExclusiveOrder: list[i].ExclusiveOrder,
|
||||||
Description: list[i].Description,
|
Description: list[i].Description,
|
||||||
Color: list[i].Color,
|
Color: list[i].Color,
|
||||||
}
|
}
|
||||||
|
@ -22,49 +22,60 @@ labels:
|
|||||||
description: Breaking change that won't be backward compatible
|
description: Breaking change that won't be backward compatible
|
||||||
- name: "Reviewed/Duplicate"
|
- name: "Reviewed/Duplicate"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 50
|
||||||
color: 616161
|
color: 616161
|
||||||
description: This issue or pull request already exists
|
description: This issue or pull request already exists
|
||||||
- name: "Reviewed/Invalid"
|
- name: "Reviewed/Invalid"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 100
|
||||||
color: 546e7a
|
color: 546e7a
|
||||||
description: Invalid issue
|
description: Invalid issue
|
||||||
- name: "Reviewed/Confirmed"
|
- name: "Reviewed/Confirmed"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 0
|
||||||
color: 795548
|
color: 795548
|
||||||
description: Issue has been confirmed
|
description: Issue has been confirmed
|
||||||
- name: "Reviewed/Won't Fix"
|
- name: "Reviewed/Won't Fix"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 75
|
||||||
color: eeeeee
|
color: eeeeee
|
||||||
description: This issue won't be fixed
|
description: This issue won't be fixed
|
||||||
- name: "Status/Need More Info"
|
- name: "Status/Need More Info"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 25
|
||||||
color: 424242
|
color: 424242
|
||||||
description: Feedback is required to reproduce issue or to continue work
|
description: Feedback is required to reproduce issue or to continue work
|
||||||
- name: "Status/Blocked"
|
- name: "Status/Blocked"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 0
|
||||||
color: 880e4f
|
color: 880e4f
|
||||||
description: Something is blocking this issue or pull request
|
description: Something is blocking this issue or pull request
|
||||||
- name: "Status/Abandoned"
|
- name: "Status/Abandoned"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 100
|
||||||
color: "222222"
|
color: "222222"
|
||||||
description: Somebody has started to work on this but abandoned work
|
description: Somebody has started to work on this but abandoned work
|
||||||
- name: "Priority/Critical"
|
- name: "Priority/Critical"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 0
|
||||||
color: b71c1c
|
color: b71c1c
|
||||||
description: The priority is critical
|
description: The priority is critical
|
||||||
priority: critical
|
priority: critical
|
||||||
- name: "Priority/High"
|
- name: "Priority/High"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 1
|
||||||
color: d32f2f
|
color: d32f2f
|
||||||
description: The priority is high
|
description: The priority is high
|
||||||
priority: high
|
priority: high
|
||||||
- name: "Priority/Medium"
|
- name: "Priority/Medium"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 2
|
||||||
color: e64a19
|
color: e64a19
|
||||||
description: The priority is medium
|
description: The priority is medium
|
||||||
priority: medium
|
priority: medium
|
||||||
- name: "Priority/Low"
|
- name: "Priority/Low"
|
||||||
exclusive: true
|
exclusive: true
|
||||||
|
exclusive_order: 3
|
||||||
color: 4caf50
|
color: 4caf50
|
||||||
description: The priority is low
|
description: The priority is low
|
||||||
priority: low
|
priority: low
|
||||||
|
Loading…
Reference in New Issue
Block a user