4 Fetch closed GitHub issues that were updated in the last 14 days.
7 function Get-GHClosed {
11 $repos = @('SecOps-Tools', 'secdev-job-aids', 'awscli-login')
12 $issueSearchParams = @{ State = 'closed'; OwnerName = 'techservicesillinois' }
14 $repos | ForEach-Object {
15 $closed += Get-GitHubIssue -RepositoryName $_ @issueSearchParams
18 # Limit to past two weeks
19 $issues = $closed | Where-Object { $_.updated_at -gt (Get-Date).AddDays($days) }
27 Fetch GitHub issues that are tagged to discuss this morning.
30 function Get-GHToDiscuss {
34 $repos = @('SecOps-Tools', 'secdev-job-aids', 'awscli-login')
35 $issueSearchParams = @{ State = 'open'; OwnerName = 'techservicesillinois' }
37 $repos | ForEach-Object {
38 $closed += Get-GitHubIssue -RepositoryName $_ @issueSearchParams
40 $issues = $issues | Where-Object { $_.labels -Contains 'DiscussAtStandUp' }
49 Show closed GitHub issues that were updated in the last 14 days.
52 function Show-GHClosed() {
56 Get-GHClosed -days $days | ForEach-Object {
58 " + [" + $_.Title + " (" + $_.Number + ")](" + $_.html_url + ")"
60 # Format-Table -Property Number, Title, Url
67 Fetch GitHub issues I am working on.
70 function Get-GHMine() {
71 $repos = @('SecOps-Tools', 'secdev-job-aids', 'awscli-login')
72 $issueSearchParams = @{ Assignee = 'edthedev'; State = 'open'; OwnerName = 'techservicesillinois' }
74 $repos | ForEach-Object {
75 $issues += Get-GitHubIssue -RepositoryName $_ @issueSearchParams
78 # Ignore issues that have been updated in the last day.
79 $issues = $issues | Where-Object { $_.updated_at -lt (Get-Date).AddDays(-1) }
87 Show GitHub issues I am working on.
90 function Show-GHMine() {
91 Get-GHMine | ForEach-Object {
93 " + [" + $_.Title + " (" + $_.Number + ")](" + $_.html_url + ")"
100 is:open is:issue -label:M -label:L -label:S -label:XL -label:XS
103 function Get-GHUnsized() {
104 $repos = @('SecOps-Tools', 'secdev-job-aids', 'awscli-login')
105 $issueSearchParams = @{ State = 'open'; OwnerName = 'techservicesillinois' }
107 $repos | ForEach-Object {
108 $issues += Get-GitHubIssue -RepositoryName $_ @issueSearchParams
111 # Ignore issues that have been updated in the last day.
112 $issues = $issues | Where-Object { -Not $_.labels -Contains 'XS' }
113 $issues = $issues | Where-Object { -Not $_.labels -Contains 'S' }
114 $issues = $issues | Where-Object { -Not $_.labels -Contains 'M' }
115 $issues = $issues | Where-Object { -Not $_.labels -Contains 'L' }
116 # Leave XL issues, as they need split.
121 function Show-GHUnsized() {
122 Get-GHUnsized | ForEach-Object {
124 " + [" + $_.Title + " (" + $_.Number + ")](" + $_.html_url + ")" + $_.labels
128 function Show-GHToDiscuss() {
129 Get-GHToDiscuss | Show-GHIssuesAsMarkdown
133 function Show-GHIssuesAsMarkdown() {
137 " + [" + $_.Title + " (" + $_.Number + ")](" + $_.html_url + ")" + $_.labels
142 Export-ModuleMember -Function Get-GHClosed
143 Export-ModuleMember -Function Show-GHClosed
144 Export-ModuleMember -Function Get-GHMine
145 Export-ModuleMember -Function Show-GHMine
146 Export-ModuleMember -Function Get-GHUnsized
147 Export-ModuleMember -Function Show-GHUnsized
148 Export-ModuleMember -Function Show-GHToDiscuss