-
Notifications
You must be signed in to change notification settings - Fork 566
73 lines (70 loc) · 2.86 KB
/
azure-devops-issue-sync.yml
File metadata and controls
73 lines (70 loc) · 2.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
name: Sync issue to Azure DevOps work item
on:
issues:
types:
[opened, labeled, edited]
jobs:
create_issues:
runs-on: ubuntu-latest
steps:
- if: contains(github.event.issue.labels.*.name, 'bug')
uses: danhellem/github-actions-issue-to-work-item@v2.1
env:
ado_token: "${{ secrets.ADO_PERSONAL_ACCESS_TOKEN }}"
github_token: "${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}"
ado_organization: "DevtronLabs"
ado_project: "Devtron"
ado_wit: "Bug"
ado_new_state: "To Do"
ado_active_state: "Doing"
ado_close_state: "Done"
ado_bypassrules: true
log_level: 100
- if: "!contains(github.event.issue.labels.*.name, 'bug')"
uses: danhellem/github-actions-issue-to-work-item@v2.1
env:
ado_token: "${{ secrets.ADO_PERSONAL_ACCESS_TOKEN }}"
github_token: "${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}"
ado_organization: "DevtronLabs"
ado_project: "Devtron"
ado_wit: "User Story"
ado_new_state: "To Do"
ado_active_state: "Doing"
ado_close_state: "Done"
ado_bypassrules: true
log_level: 100
- if: github.event.label.name == 'pager-duty'
name: custom issues
env:
DISCORD_WEBHOOK: ${{ secrets.GH_ISSUES_DISCORD_WEBHOOK }}
DISCORD_WEBHOOK_FORUM: ${{ secrets.PAGERDUTY_DISCORD_WEBHOOK }}
ENABLE_FORUM: true
uses: devtron-labs/action-discord@master
with:
args: " ${{ github.event.issue.title }} ${{ github.event.issue.html_url }}"
potential_duplicate_issue:
runs-on: ubuntu-latest
steps:
- uses: wow-actions/potential-duplicates@v1
with:
GITHUB_TOKEN: "${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}"
# Issue title filter work with anymatch https://www.npmjs.com/package/anymatch.
# Any matched issue will stop detection immediately.
# You can specify multi filters in each line.
filter: ''
# Exclude keywords in title before detecting.
exclude: ''
# Label to set, when potential duplicates are detected.
label: potential-duplicate
# Get issues with state to compare. Supported state: 'all', 'closed', 'open'.
state: open
# If similarity is higher than this threshold([0,1]), issue will be marked as duplicate.
threshold: 0.6
# Reactions to be add to comment when potential duplicates are detected.
# Available reactions: "-1", "+1", "confused", "laugh", "heart", "hooray", "rocket", "eyes"
reactions: 'eyes, confused'
# Comment to post when potential duplicates are detected.
comment: >
Potential duplicates: {{#issues}}
- [#{{ number }}] {{ title }} ({{ accuracy }}%)
{{/issues}}