mirror of
https://github.com/actions/stale.git
synced 2025-12-27 02:38:17 +00:00
Compare commits
7 Commits
issue-596/
...
v6
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5ebf00ea0e | ||
|
|
3de2653986 | ||
|
|
02e44c81cc | ||
|
|
99b6c70959 | ||
|
|
8e8a0e6680 | ||
|
|
80962c1062 | ||
|
|
3e4418e47e |
10
CHANGELOG.md
10
CHANGELOG.md
@@ -1,18 +1,22 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
# [6.0.0]
|
||||||
|
|
||||||
|
:warning: Breaking change :warning:
|
||||||
|
|
||||||
|
Issues/PRs default `close-issue-reason` is now `not_planned`([#789](https://github.com/actions/stale/issues/789))
|
||||||
|
|
||||||
# [5.1.0]
|
# [5.1.0]
|
||||||
|
|
||||||
[Don't process stale issues right after they're marked stale](https://github.com/actions/stale/issues/696)
|
[Don't process stale issues right after they're marked stale](https://github.com/actions/stale/issues/696)
|
||||||
[Add close-issue-reason option][#764](https://github.com/actions/stale/pull/764)[#772](https://github.com/actions/stale/pull/772)
|
[Add close-issue-reason option][#764](https://github.com/actions/stale/pull/764)[#772](https://github.com/actions/stale/pull/772)
|
||||||
Various dependabot/dependency updates
|
Various dependabot/dependency updates
|
||||||
|
|
||||||
|
|
||||||
## [4.1.0](https://github.com/actions/stale/compare/v3.0.19...v4.1.0) (2021-07-14)
|
## [4.1.0](https://github.com/actions/stale/compare/v3.0.19...v4.1.0) (2021-07-14)
|
||||||
|
|
||||||
## Features
|
## Features
|
||||||
|
|
||||||
- [Ability to exempt draft PRs](https://github.com/actions/stale/commit/9912fa74d1c01b5d6187793d97441019cbe325d0
|
- [Ability to exempt draft PRs](https://github.com/actions/stale/commit/9912fa74d1c01b5d6187793d97441019cbe325d0)
|
||||||
)
|
|
||||||
|
|
||||||
## [4.0.0](https://github.com/actions/stale/compare/v3.0.19...v4.0.0) (2021-07-14)
|
## [4.0.0](https://github.com/actions/stale/compare/v3.0.19...v4.0.0) (2021-07-14)
|
||||||
|
|
||||||
|
|||||||
33
README.md
33
README.md
@@ -44,7 +44,7 @@ Every argument is optional.
|
|||||||
| [close-pr-message](#close-pr-message) | Comment on the staled PRs while closed | |
|
| [close-pr-message](#close-pr-message) | Comment on the staled PRs while closed | |
|
||||||
| [stale-issue-label](#stale-issue-label) | Label to apply on staled issues | `Stale` |
|
| [stale-issue-label](#stale-issue-label) | Label to apply on staled issues | `Stale` |
|
||||||
| [close-issue-label](#close-issue-label) | Label to apply on closed issues | |
|
| [close-issue-label](#close-issue-label) | Label to apply on closed issues | |
|
||||||
| [close-issue-reason](#close-issue-reason) | Reason to use when closing issues | |
|
| [close-issue-reason](#close-issue-reason) | Reason to use when closing issues | `not_planned` |
|
||||||
| [stale-pr-label](#stale-pr-label) | Label to apply on staled PRs | `Stale` |
|
| [stale-pr-label](#stale-pr-label) | Label to apply on staled PRs | `Stale` |
|
||||||
| [close-pr-label](#close-pr-label) | Label to apply on closed PRs | |
|
| [close-pr-label](#close-pr-label) | Label to apply on closed PRs | |
|
||||||
| [exempt-issue-labels](#exempt-issue-labels) | Labels on issues exempted from stale | |
|
| [exempt-issue-labels](#exempt-issue-labels) | Labels on issues exempted from stale | |
|
||||||
@@ -82,6 +82,7 @@ Every argument is optional.
|
|||||||
| [ignore-updates](#ignore-updates) | Any update (update/comment) can reset the stale idle time on the issues/PRs | `false` |
|
| [ignore-updates](#ignore-updates) | Any update (update/comment) can reset the stale idle time on the issues/PRs | `false` |
|
||||||
| [ignore-issue-updates](#ignore-issue-updates) | Override [ignore-updates](#ignore-updates) for issues only | |
|
| [ignore-issue-updates](#ignore-issue-updates) | Override [ignore-updates](#ignore-updates) for issues only | |
|
||||||
| [ignore-pr-updates](#ignore-pr-updates) | Override [ignore-updates](#ignore-updates) for PRs only | |
|
| [ignore-pr-updates](#ignore-pr-updates) | Override [ignore-updates](#ignore-updates) for PRs only | |
|
||||||
|
| [include-only-assigned](#include-only-assigned) | Process only assigned issues | `false` |
|
||||||
|
|
||||||
### List of output options
|
### List of output options
|
||||||
|
|
||||||
@@ -225,7 +226,7 @@ Required Permission: `issues: write`
|
|||||||
|
|
||||||
Specify the [reason](https://github.blog/changelog/2022-05-19-the-new-github-issues-may-19th-update/) used when closing issues. Valid values are `completed` and `not_planned`.
|
Specify the [reason](https://github.blog/changelog/2022-05-19-the-new-github-issues-may-19th-update/) used when closing issues. Valid values are `completed` and `not_planned`.
|
||||||
|
|
||||||
Default value: unset
|
Default value: `not_planned`
|
||||||
|
|
||||||
#### stale-pr-label
|
#### stale-pr-label
|
||||||
|
|
||||||
@@ -517,6 +518,12 @@ Useful to override [ignore-updates](#ignore-updates) but only to ignore the upda
|
|||||||
|
|
||||||
Default value: unset
|
Default value: unset
|
||||||
|
|
||||||
|
#### include-only-assigned
|
||||||
|
|
||||||
|
If set to `true`, only the issues or the pull requests with an assignee will be marked as stale automatically.
|
||||||
|
|
||||||
|
Default value: `false`
|
||||||
|
|
||||||
### Usage
|
### Usage
|
||||||
|
|
||||||
See also [action.yml](./action.yml) for a comprehensive list of all the options.
|
See also [action.yml](./action.yml) for a comprehensive list of all the options.
|
||||||
@@ -533,7 +540,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
stale-issue-message: 'Message to comment on stale issues. If none provided, will not mark issues stale'
|
stale-issue-message: 'Message to comment on stale issues. If none provided, will not mark issues stale'
|
||||||
stale-pr-message: 'Message to comment on stale PRs. If none provided, will not mark PRs stale'
|
stale-pr-message: 'Message to comment on stale PRs. If none provided, will not mark PRs stale'
|
||||||
@@ -551,7 +558,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
||||||
days-before-stale: 30
|
days-before-stale: 30
|
||||||
@@ -570,7 +577,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
||||||
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
|
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
|
||||||
@@ -592,7 +599,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.'
|
||||||
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
|
stale-pr-message: 'This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.'
|
||||||
@@ -616,7 +623,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
stale-issue-message: 'Stale issue message'
|
stale-issue-message: 'Stale issue message'
|
||||||
stale-pr-message: 'Stale pull request message'
|
stale-pr-message: 'Stale pull request message'
|
||||||
@@ -639,7 +646,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
start-date: '2020-04-18T00:00:00Z' # ISO 8601 or RFC 2822
|
start-date: '2020-04-18T00:00:00Z' # ISO 8601 or RFC 2822
|
||||||
```
|
```
|
||||||
@@ -656,7 +663,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
exempt-issue-milestones: 'future,alpha,beta'
|
exempt-issue-milestones: 'future,alpha,beta'
|
||||||
exempt-pr-milestones: 'bugfix,improvement'
|
exempt-pr-milestones: 'bugfix,improvement'
|
||||||
@@ -674,7 +681,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
exempt-all-pr-milestones: true
|
exempt-all-pr-milestones: true
|
||||||
```
|
```
|
||||||
@@ -691,7 +698,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
any-of-labels: 'needs-more-info,needs-demo'
|
any-of-labels: 'needs-more-info,needs-demo'
|
||||||
# You can opt for 'only-labels' instead if your use-case requires all labels
|
# You can opt for 'only-labels' instead if your use-case requires all labels
|
||||||
@@ -710,7 +717,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
exempt-issue-assignees: 'marco,polo'
|
exempt-issue-assignees: 'marco,polo'
|
||||||
exempt-pr-assignees: 'marco'
|
exempt-pr-assignees: 'marco'
|
||||||
@@ -728,7 +735,7 @@ jobs:
|
|||||||
stale:
|
stale:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v5
|
- uses: actions/stale@v6
|
||||||
with:
|
with:
|
||||||
exempt-all-pr-assignees: true
|
exempt-all-pr-assignees: true
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
import {IIssuesProcessorOptions} from '../../src/interfaces/issues-processor-options';
|
import {IIssuesProcessorOptions} from '../../src/interfaces/issues-processor-options';
|
||||||
|
|
||||||
|
// Default options for use in tests.
|
||||||
|
// Mirrors the defaults defined in action.yml
|
||||||
export const DefaultProcessorOptions: IIssuesProcessorOptions = Object.freeze({
|
export const DefaultProcessorOptions: IIssuesProcessorOptions = Object.freeze({
|
||||||
repoToken: 'none',
|
repoToken: 'none',
|
||||||
staleIssueMessage: 'This issue is stale',
|
staleIssueMessage: 'This issue is stale',
|
||||||
@@ -51,5 +53,6 @@ export const DefaultProcessorOptions: IIssuesProcessorOptions = Object.freeze({
|
|||||||
ignoreIssueUpdates: undefined,
|
ignoreIssueUpdates: undefined,
|
||||||
ignorePrUpdates: undefined,
|
ignorePrUpdates: undefined,
|
||||||
exemptDraftPr: false,
|
exemptDraftPr: false,
|
||||||
closeIssueReason: ''
|
closeIssueReason: 'not_planned',
|
||||||
|
includeOnlyAssigned: false
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -2352,3 +2352,69 @@ test('processing a pull request to be stale with the "stalePrMessage" option set
|
|||||||
expect(processor.closedIssues).toHaveLength(0);
|
expect(processor.closedIssues).toHaveLength(0);
|
||||||
expect(processor.statistics?.addedPullRequestsCommentsCount).toStrictEqual(0);
|
expect(processor.statistics?.addedPullRequestsCommentsCount).toStrictEqual(0);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('processing an issue with the "includeOnlyAssigned" option and nonempty assignee list will stale the issue', async () => {
|
||||||
|
const issueDate = new Date();
|
||||||
|
issueDate.setDate(issueDate.getDate() - 2);
|
||||||
|
|
||||||
|
const opts: IIssuesProcessorOptions = {
|
||||||
|
...DefaultProcessorOptions,
|
||||||
|
staleIssueLabel: 'This issue is stale',
|
||||||
|
includeOnlyAssigned: true
|
||||||
|
};
|
||||||
|
|
||||||
|
const TestIssueList: Issue[] = [
|
||||||
|
generateIssue(
|
||||||
|
opts,
|
||||||
|
1,
|
||||||
|
'An issue with no label',
|
||||||
|
issueDate.toDateString(),
|
||||||
|
issueDate.toDateString(),
|
||||||
|
false,
|
||||||
|
[],
|
||||||
|
false,
|
||||||
|
false,
|
||||||
|
undefined,
|
||||||
|
['assignee1']
|
||||||
|
)
|
||||||
|
];
|
||||||
|
const processor = new IssuesProcessorMock(
|
||||||
|
opts,
|
||||||
|
async p => (p === 1 ? TestIssueList : []),
|
||||||
|
async () => [],
|
||||||
|
async () => new Date().toDateString()
|
||||||
|
);
|
||||||
|
|
||||||
|
// process our fake issue list
|
||||||
|
await processor.processIssues(1);
|
||||||
|
|
||||||
|
expect(processor.staleIssues).toHaveLength(1);
|
||||||
|
expect(processor.closedIssues).toHaveLength(0);
|
||||||
|
});
|
||||||
|
|
||||||
|
test('processing an issue with the "includeOnlyAssigned" option set and no assignees will not stale the issue', async () => {
|
||||||
|
const issueDate = new Date();
|
||||||
|
issueDate.setDate(issueDate.getDate() - 2);
|
||||||
|
|
||||||
|
const opts: IIssuesProcessorOptions = {
|
||||||
|
...DefaultProcessorOptions,
|
||||||
|
staleIssueLabel: 'This issue is stale',
|
||||||
|
includeOnlyAssigned: true
|
||||||
|
};
|
||||||
|
|
||||||
|
const TestIssueList: Issue[] = [
|
||||||
|
generateIssue(opts, 1, 'An issue with no label', issueDate.toDateString())
|
||||||
|
];
|
||||||
|
const processor = new IssuesProcessorMock(
|
||||||
|
opts,
|
||||||
|
async p => (p === 1 ? TestIssueList : []),
|
||||||
|
async () => [],
|
||||||
|
async () => new Date().toDateString()
|
||||||
|
);
|
||||||
|
|
||||||
|
// process our fake issue list
|
||||||
|
await processor.processIssues(1);
|
||||||
|
|
||||||
|
expect(processor.staleIssues).toHaveLength(0);
|
||||||
|
expect(processor.closedIssues).toHaveLength(0);
|
||||||
|
});
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ inputs:
|
|||||||
required: false
|
required: false
|
||||||
close-issue-reason:
|
close-issue-reason:
|
||||||
description: 'The reason to use when closing an issue.'
|
description: 'The reason to use when closing an issue.'
|
||||||
default: ''
|
default: 'not_planned'
|
||||||
required: false
|
required: false
|
||||||
stale-pr-label:
|
stale-pr-label:
|
||||||
description: 'The label to apply when a pull request is stale.'
|
description: 'The label to apply when a pull request is stale.'
|
||||||
@@ -196,6 +196,10 @@ inputs:
|
|||||||
description: 'Any update (update/comment) can reset the stale idle time on the pull requests. Override "ignore-updates" option regarding only the pull requests.'
|
description: 'Any update (update/comment) can reset the stale idle time on the pull requests. Override "ignore-updates" option regarding only the pull requests.'
|
||||||
default: ''
|
default: ''
|
||||||
required: false
|
required: false
|
||||||
|
include-only-assigned:
|
||||||
|
description: 'Only the issues or the pull requests with an assignee will be marked as stale automatically.'
|
||||||
|
default: 'false'
|
||||||
|
required: false
|
||||||
outputs:
|
outputs:
|
||||||
closed-issues-prs:
|
closed-issues-prs:
|
||||||
description: 'List of all closed issues and pull requests.'
|
description: 'List of all closed issues and pull requests.'
|
||||||
|
|||||||
89
dist/index.js
vendored
89
dist/index.js
vendored
@@ -476,6 +476,11 @@ class IssuesProcessor {
|
|||||||
IssuesProcessor._endIssueProcessing(issue);
|
IssuesProcessor._endIssueProcessing(issue);
|
||||||
return; // Don't process locked issues
|
return; // Don't process locked issues
|
||||||
}
|
}
|
||||||
|
if (this._isIncludeOnlyAssigned(issue)) {
|
||||||
|
issueLogger.info(`Skipping this $$type because its assignees list is empty`);
|
||||||
|
IssuesProcessor._endIssueProcessing(issue);
|
||||||
|
return; // If the issue has an 'include-only-assigned' option set, process only issues with nonempty assignees list
|
||||||
|
}
|
||||||
const onlyLabels = words_to_list_1.wordsToList(this._getOnlyLabels(issue));
|
const onlyLabels = words_to_list_1.wordsToList(this._getOnlyLabels(issue));
|
||||||
if (onlyLabels.length > 0) {
|
if (onlyLabels.length > 0) {
|
||||||
issueLogger.info(`The option ${issueLogger.createOptionLink(option_1.Option.OnlyLabels)} was specified to only process issues and pull requests with all those labels (${logger_service_1.LoggerService.cyan(onlyLabels.length)})`);
|
issueLogger.info(`The option ${issueLogger.createOptionLink(option_1.Option.OnlyLabels)} was specified to only process issues and pull requests with all those labels (${logger_service_1.LoggerService.cyan(onlyLabels.length)})`);
|
||||||
@@ -737,7 +742,9 @@ class IssuesProcessor {
|
|||||||
if (issue.markedStaleThisRun) {
|
if (issue.markedStaleThisRun) {
|
||||||
issueLogger.info(`marked stale this run, so don't check for updates`);
|
issueLogger.info(`marked stale this run, so don't check for updates`);
|
||||||
}
|
}
|
||||||
const issueHasUpdateSinceStale = new Date(issue.updated_at) > new Date(markedStaleOn);
|
// The issue.updated_at and markedStaleOn are not always exactly in sync (they can be off by a second or 2)
|
||||||
|
// isDateMoreRecentThan makes sure they are not the same date within a certain tolerance (15 seconds in this case)
|
||||||
|
const issueHasUpdateSinceStale = is_date_more_recent_than_1.isDateMoreRecentThan(new Date(issue.updated_at), new Date(markedStaleOn), 15);
|
||||||
issueLogger.info(`$$type has been updated since it was marked stale: ${logger_service_1.LoggerService.cyan(issueHasUpdateSinceStale)}`);
|
issueLogger.info(`$$type has been updated since it was marked stale: ${logger_service_1.LoggerService.cyan(issueHasUpdateSinceStale)}`);
|
||||||
// Should we un-stale this issue?
|
// Should we un-stale this issue?
|
||||||
if (shouldRemoveStaleWhenUpdated &&
|
if (shouldRemoveStaleWhenUpdated &&
|
||||||
@@ -988,6 +995,9 @@ class IssuesProcessor {
|
|||||||
}
|
}
|
||||||
return this.options.onlyLabels;
|
return this.options.onlyLabels;
|
||||||
}
|
}
|
||||||
|
_isIncludeOnlyAssigned(issue) {
|
||||||
|
return this.options.includeOnlyAssigned && !issue.hasAssignees;
|
||||||
|
}
|
||||||
_getAnyOfLabels(issue) {
|
_getAnyOfLabels(issue) {
|
||||||
if (issue.isPullRequest) {
|
if (issue.isPullRequest) {
|
||||||
if (this.options.anyOfPrLabels !== '') {
|
if (this.options.anyOfPrLabels !== '') {
|
||||||
@@ -1957,12 +1967,25 @@ exports.getHumanizedDate = getHumanizedDate;
|
|||||||
|
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
|
/// returns false if the dates are equal within the `equalityToleranceInSeconds` number of seconds
|
||||||
|
/// otherwise returns true if `comparedDate` is after `date`
|
||||||
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||||
exports.isDateMoreRecentThan = void 0;
|
exports.isDateEqualTo = exports.isDateMoreRecentThan = void 0;
|
||||||
function isDateMoreRecentThan(date, comparedDate) {
|
function isDateMoreRecentThan(date, comparedDate, equalityToleranceInSeconds = 0) {
|
||||||
|
if (equalityToleranceInSeconds > 0) {
|
||||||
|
const areDatesEqual = isDateEqualTo(date, comparedDate, equalityToleranceInSeconds);
|
||||||
|
return !areDatesEqual && date > comparedDate;
|
||||||
|
}
|
||||||
return date > comparedDate;
|
return date > comparedDate;
|
||||||
}
|
}
|
||||||
exports.isDateMoreRecentThan = isDateMoreRecentThan;
|
exports.isDateMoreRecentThan = isDateMoreRecentThan;
|
||||||
|
function isDateEqualTo(date, otherDate, toleranceInSeconds) {
|
||||||
|
const timestamp = date.getTime();
|
||||||
|
const otherTimestamp = otherDate.getTime();
|
||||||
|
const deltaInSeconds = Math.abs(timestamp - otherTimestamp) / 1000;
|
||||||
|
return deltaInSeconds <= toleranceInSeconds;
|
||||||
|
}
|
||||||
|
exports.isDateEqualTo = isDateEqualTo;
|
||||||
|
|
||||||
|
|
||||||
/***/ }),
|
/***/ }),
|
||||||
@@ -2207,7 +2230,8 @@ function _getAndValidateArgs() {
|
|||||||
ignoreIssueUpdates: _toOptionalBoolean('ignore-issue-updates'),
|
ignoreIssueUpdates: _toOptionalBoolean('ignore-issue-updates'),
|
||||||
ignorePrUpdates: _toOptionalBoolean('ignore-pr-updates'),
|
ignorePrUpdates: _toOptionalBoolean('ignore-pr-updates'),
|
||||||
exemptDraftPr: core.getInput('exempt-draft-pr') === 'true',
|
exemptDraftPr: core.getInput('exempt-draft-pr') === 'true',
|
||||||
closeIssueReason: core.getInput('close-issue-reason')
|
closeIssueReason: core.getInput('close-issue-reason'),
|
||||||
|
includeOnlyAssigned: core.getInput('include-only-assigned') === 'true'
|
||||||
};
|
};
|
||||||
for (const numberInput of [
|
for (const numberInput of [
|
||||||
'days-before-stale',
|
'days-before-stale',
|
||||||
@@ -2460,7 +2484,6 @@ const file_command_1 = __nccwpck_require__(717);
|
|||||||
const utils_1 = __nccwpck_require__(5278);
|
const utils_1 = __nccwpck_require__(5278);
|
||||||
const os = __importStar(__nccwpck_require__(2087));
|
const os = __importStar(__nccwpck_require__(2087));
|
||||||
const path = __importStar(__nccwpck_require__(5622));
|
const path = __importStar(__nccwpck_require__(5622));
|
||||||
const uuid_1 = __nccwpck_require__(5840);
|
|
||||||
const oidc_utils_1 = __nccwpck_require__(8041);
|
const oidc_utils_1 = __nccwpck_require__(8041);
|
||||||
/**
|
/**
|
||||||
* The code to exit an action
|
* The code to exit an action
|
||||||
@@ -2490,20 +2513,9 @@ function exportVariable(name, val) {
|
|||||||
process.env[name] = convertedVal;
|
process.env[name] = convertedVal;
|
||||||
const filePath = process.env['GITHUB_ENV'] || '';
|
const filePath = process.env['GITHUB_ENV'] || '';
|
||||||
if (filePath) {
|
if (filePath) {
|
||||||
const delimiter = `ghadelimiter_${uuid_1.v4()}`;
|
return file_command_1.issueFileCommand('ENV', file_command_1.prepareKeyValueMessage(name, val));
|
||||||
// These should realistically never happen, but just in case someone finds a way to exploit uuid generation let's not allow keys or values that contain the delimiter.
|
|
||||||
if (name.includes(delimiter)) {
|
|
||||||
throw new Error(`Unexpected input: name should not contain the delimiter "${delimiter}"`);
|
|
||||||
}
|
|
||||||
if (convertedVal.includes(delimiter)) {
|
|
||||||
throw new Error(`Unexpected input: value should not contain the delimiter "${delimiter}"`);
|
|
||||||
}
|
|
||||||
const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`;
|
|
||||||
file_command_1.issueCommand('ENV', commandValue);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
command_1.issueCommand('set-env', { name }, convertedVal);
|
|
||||||
}
|
}
|
||||||
|
command_1.issueCommand('set-env', { name }, convertedVal);
|
||||||
}
|
}
|
||||||
exports.exportVariable = exportVariable;
|
exports.exportVariable = exportVariable;
|
||||||
/**
|
/**
|
||||||
@@ -2521,7 +2533,7 @@ exports.setSecret = setSecret;
|
|||||||
function addPath(inputPath) {
|
function addPath(inputPath) {
|
||||||
const filePath = process.env['GITHUB_PATH'] || '';
|
const filePath = process.env['GITHUB_PATH'] || '';
|
||||||
if (filePath) {
|
if (filePath) {
|
||||||
file_command_1.issueCommand('PATH', inputPath);
|
file_command_1.issueFileCommand('PATH', inputPath);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
command_1.issueCommand('add-path', {}, inputPath);
|
command_1.issueCommand('add-path', {}, inputPath);
|
||||||
@@ -2561,7 +2573,10 @@ function getMultilineInput(name, options) {
|
|||||||
const inputs = getInput(name, options)
|
const inputs = getInput(name, options)
|
||||||
.split('\n')
|
.split('\n')
|
||||||
.filter(x => x !== '');
|
.filter(x => x !== '');
|
||||||
return inputs;
|
if (options && options.trimWhitespace === false) {
|
||||||
|
return inputs;
|
||||||
|
}
|
||||||
|
return inputs.map(input => input.trim());
|
||||||
}
|
}
|
||||||
exports.getMultilineInput = getMultilineInput;
|
exports.getMultilineInput = getMultilineInput;
|
||||||
/**
|
/**
|
||||||
@@ -2594,8 +2609,12 @@ exports.getBooleanInput = getBooleanInput;
|
|||||||
*/
|
*/
|
||||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||||
function setOutput(name, value) {
|
function setOutput(name, value) {
|
||||||
|
const filePath = process.env['GITHUB_OUTPUT'] || '';
|
||||||
|
if (filePath) {
|
||||||
|
return file_command_1.issueFileCommand('OUTPUT', file_command_1.prepareKeyValueMessage(name, value));
|
||||||
|
}
|
||||||
process.stdout.write(os.EOL);
|
process.stdout.write(os.EOL);
|
||||||
command_1.issueCommand('set-output', { name }, value);
|
command_1.issueCommand('set-output', { name }, utils_1.toCommandValue(value));
|
||||||
}
|
}
|
||||||
exports.setOutput = setOutput;
|
exports.setOutput = setOutput;
|
||||||
/**
|
/**
|
||||||
@@ -2724,7 +2743,11 @@ exports.group = group;
|
|||||||
*/
|
*/
|
||||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||||
function saveState(name, value) {
|
function saveState(name, value) {
|
||||||
command_1.issueCommand('save-state', { name }, value);
|
const filePath = process.env['GITHUB_STATE'] || '';
|
||||||
|
if (filePath) {
|
||||||
|
return file_command_1.issueFileCommand('STATE', file_command_1.prepareKeyValueMessage(name, value));
|
||||||
|
}
|
||||||
|
command_1.issueCommand('save-state', { name }, utils_1.toCommandValue(value));
|
||||||
}
|
}
|
||||||
exports.saveState = saveState;
|
exports.saveState = saveState;
|
||||||
/**
|
/**
|
||||||
@@ -2790,13 +2813,14 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||||
exports.issueCommand = void 0;
|
exports.prepareKeyValueMessage = exports.issueFileCommand = void 0;
|
||||||
// We use any as a valid input type
|
// We use any as a valid input type
|
||||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||||
const fs = __importStar(__nccwpck_require__(5747));
|
const fs = __importStar(__nccwpck_require__(5747));
|
||||||
const os = __importStar(__nccwpck_require__(2087));
|
const os = __importStar(__nccwpck_require__(2087));
|
||||||
|
const uuid_1 = __nccwpck_require__(5840);
|
||||||
const utils_1 = __nccwpck_require__(5278);
|
const utils_1 = __nccwpck_require__(5278);
|
||||||
function issueCommand(command, message) {
|
function issueFileCommand(command, message) {
|
||||||
const filePath = process.env[`GITHUB_${command}`];
|
const filePath = process.env[`GITHUB_${command}`];
|
||||||
if (!filePath) {
|
if (!filePath) {
|
||||||
throw new Error(`Unable to find environment variable for file command ${command}`);
|
throw new Error(`Unable to find environment variable for file command ${command}`);
|
||||||
@@ -2808,7 +2832,22 @@ function issueCommand(command, message) {
|
|||||||
encoding: 'utf8'
|
encoding: 'utf8'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
exports.issueCommand = issueCommand;
|
exports.issueFileCommand = issueFileCommand;
|
||||||
|
function prepareKeyValueMessage(key, value) {
|
||||||
|
const delimiter = `ghadelimiter_${uuid_1.v4()}`;
|
||||||
|
const convertedValue = utils_1.toCommandValue(value);
|
||||||
|
// These should realistically never happen, but just in case someone finds a
|
||||||
|
// way to exploit uuid generation let's not allow keys or values that contain
|
||||||
|
// the delimiter.
|
||||||
|
if (key.includes(delimiter)) {
|
||||||
|
throw new Error(`Unexpected input: name should not contain the delimiter "${delimiter}"`);
|
||||||
|
}
|
||||||
|
if (convertedValue.includes(delimiter)) {
|
||||||
|
throw new Error(`Unexpected input: value should not contain the delimiter "${delimiter}"`);
|
||||||
|
}
|
||||||
|
return `${key}<<${delimiter}${os.EOL}${convertedValue}${os.EOL}${delimiter}`;
|
||||||
|
}
|
||||||
|
exports.prepareKeyValueMessage = prepareKeyValueMessage;
|
||||||
//# sourceMappingURL=file-command.js.map
|
//# sourceMappingURL=file-command.js.map
|
||||||
|
|
||||||
/***/ }),
|
/***/ }),
|
||||||
|
|||||||
14
package-lock.json
generated
14
package-lock.json
generated
@@ -9,7 +9,7 @@
|
|||||||
"version": "2.0.0",
|
"version": "2.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/core": "^1.2.6",
|
"@actions/core": "^1.10.0",
|
||||||
"@actions/github": "^5.0.1",
|
"@actions/github": "^5.0.1",
|
||||||
"lodash.deburr": "^4.1.0",
|
"lodash.deburr": "^4.1.0",
|
||||||
"semver": "^7.3.5"
|
"semver": "^7.3.5"
|
||||||
@@ -42,9 +42,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@actions/core": {
|
"node_modules/@actions/core": {
|
||||||
"version": "1.9.1",
|
"version": "1.10.0",
|
||||||
"resolved": "https://registry.npmjs.org/@actions/core/-/core-1.9.1.tgz",
|
"resolved": "https://registry.npmjs.org/@actions/core/-/core-1.10.0.tgz",
|
||||||
"integrity": "sha512-5ad+U2YGrmmiw6du20AQW5XuWo7UKN2052FjSV7MX+Wfjf8sCqcsZe62NfgHys4QI4/Y+vQvLKYL8jWtA1ZBTA==",
|
"integrity": "sha512-2aZDDa3zrrZbP5ZYg159sNoLRb61nQ7awl5pSvIq5Qpj81vwDzdMRKzkWJGJuwVvWpvZKx7vspJALyvaaIQyug==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/http-client": "^2.0.1",
|
"@actions/http-client": "^2.0.1",
|
||||||
"uuid": "^8.3.2"
|
"uuid": "^8.3.2"
|
||||||
@@ -11187,9 +11187,9 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/core": {
|
"@actions/core": {
|
||||||
"version": "1.9.1",
|
"version": "1.10.0",
|
||||||
"resolved": "https://registry.npmjs.org/@actions/core/-/core-1.9.1.tgz",
|
"resolved": "https://registry.npmjs.org/@actions/core/-/core-1.10.0.tgz",
|
||||||
"integrity": "sha512-5ad+U2YGrmmiw6du20AQW5XuWo7UKN2052FjSV7MX+Wfjf8sCqcsZe62NfgHys4QI4/Y+vQvLKYL8jWtA1ZBTA==",
|
"integrity": "sha512-2aZDDa3zrrZbP5ZYg159sNoLRb61nQ7awl5pSvIq5Qpj81vwDzdMRKzkWJGJuwVvWpvZKx7vspJALyvaaIQyug==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@actions/http-client": "^2.0.1",
|
"@actions/http-client": "^2.0.1",
|
||||||
"uuid": "^8.3.2"
|
"uuid": "^8.3.2"
|
||||||
|
|||||||
@@ -38,7 +38,7 @@
|
|||||||
"author": "GitHub",
|
"author": "GitHub",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@actions/core": "^1.2.6",
|
"@actions/core": "^1.10.0",
|
||||||
"@actions/github": "^5.0.1",
|
"@actions/github": "^5.0.1",
|
||||||
"lodash.deburr": "^4.1.0",
|
"lodash.deburr": "^4.1.0",
|
||||||
"semver": "^7.3.5"
|
"semver": "^7.3.5"
|
||||||
|
|||||||
@@ -62,7 +62,8 @@ describe('Issue', (): void => {
|
|||||||
ignoreIssueUpdates: undefined,
|
ignoreIssueUpdates: undefined,
|
||||||
ignorePrUpdates: undefined,
|
ignorePrUpdates: undefined,
|
||||||
exemptDraftPr: false,
|
exemptDraftPr: false,
|
||||||
closeIssueReason: ''
|
closeIssueReason: '',
|
||||||
|
includeOnlyAssigned: false
|
||||||
};
|
};
|
||||||
issueInterface = {
|
issueInterface = {
|
||||||
title: 'dummy-title',
|
title: 'dummy-title',
|
||||||
|
|||||||
@@ -221,6 +221,14 @@ export class IssuesProcessor {
|
|||||||
return; // Don't process locked issues
|
return; // Don't process locked issues
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (this._isIncludeOnlyAssigned(issue)) {
|
||||||
|
issueLogger.info(
|
||||||
|
`Skipping this $$type because its assignees list is empty`
|
||||||
|
);
|
||||||
|
IssuesProcessor._endIssueProcessing(issue);
|
||||||
|
return; // If the issue has an 'include-only-assigned' option set, process only issues with nonempty assignees list
|
||||||
|
}
|
||||||
|
|
||||||
const onlyLabels: string[] = wordsToList(this._getOnlyLabels(issue));
|
const onlyLabels: string[] = wordsToList(this._getOnlyLabels(issue));
|
||||||
|
|
||||||
if (onlyLabels.length > 0) {
|
if (onlyLabels.length > 0) {
|
||||||
@@ -665,8 +673,13 @@ export class IssuesProcessor {
|
|||||||
issueLogger.info(`marked stale this run, so don't check for updates`);
|
issueLogger.info(`marked stale this run, so don't check for updates`);
|
||||||
}
|
}
|
||||||
|
|
||||||
const issueHasUpdateSinceStale =
|
// The issue.updated_at and markedStaleOn are not always exactly in sync (they can be off by a second or 2)
|
||||||
new Date(issue.updated_at) > new Date(markedStaleOn);
|
// isDateMoreRecentThan makes sure they are not the same date within a certain tolerance (15 seconds in this case)
|
||||||
|
const issueHasUpdateSinceStale = isDateMoreRecentThan(
|
||||||
|
new Date(issue.updated_at),
|
||||||
|
new Date(markedStaleOn),
|
||||||
|
15
|
||||||
|
);
|
||||||
|
|
||||||
issueLogger.info(
|
issueLogger.info(
|
||||||
`$$type has been updated since it was marked stale: ${LoggerService.cyan(
|
`$$type has been updated since it was marked stale: ${LoggerService.cyan(
|
||||||
@@ -1012,6 +1025,10 @@ export class IssuesProcessor {
|
|||||||
return this.options.onlyLabels;
|
return this.options.onlyLabels;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private _isIncludeOnlyAssigned(issue: Issue): boolean {
|
||||||
|
return this.options.includeOnlyAssigned && !issue.hasAssignees;
|
||||||
|
}
|
||||||
|
|
||||||
private _getAnyOfLabels(issue: Issue): string {
|
private _getAnyOfLabels(issue: Issue): string {
|
||||||
if (issue.isPullRequest) {
|
if (issue.isPullRequest) {
|
||||||
if (this.options.anyOfPrLabels !== '') {
|
if (this.options.anyOfPrLabels !== '') {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import {isDateMoreRecentThan} from './is-date-more-recent-than';
|
import {isDateEqualTo, isDateMoreRecentThan} from './is-date-more-recent-than';
|
||||||
|
|
||||||
describe('isDateMoreRecentThan()', (): void => {
|
describe('isDateMoreRecentThan()', (): void => {
|
||||||
let date: Date;
|
let date: Date;
|
||||||
@@ -48,4 +48,68 @@ describe('isDateMoreRecentThan()', (): void => {
|
|||||||
expect(result).toStrictEqual(true);
|
expect(result).toStrictEqual(true);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
describe('date equality', (): void => {
|
||||||
|
it('should correctly compare a before date outside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T14:00:00');
|
||||||
|
expect(isDateEqualTo(aDate, otherDate, 60)).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare a before date inside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T13:00:42');
|
||||||
|
expect(isDateEqualTo(aDate, otherDate, 60)).toBe(true);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an after date outside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T12:00:00');
|
||||||
|
expect(isDateEqualTo(aDate, otherDate, 60)).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an after date inside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T12:59:42');
|
||||||
|
expect(isDateEqualTo(aDate, otherDate, 60)).toBe(true);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an exactly equal date', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T13:00:00');
|
||||||
|
expect(isDateEqualTo(aDate, otherDate, 60)).toBe(true);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
describe('date comparison with tolerances', (): void => {
|
||||||
|
it('should correctly compare a before date outside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T14:00:00');
|
||||||
|
expect(isDateMoreRecentThan(aDate, otherDate)).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare a before date inside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T13:00:42');
|
||||||
|
expect(isDateMoreRecentThan(aDate, otherDate, 60)).toBe(false); // considered equal here
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an after date outside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T12:00:00');
|
||||||
|
expect(isDateMoreRecentThan(aDate, otherDate, 60)).toBe(true);
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an after date inside tolerance', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T12:59:42');
|
||||||
|
expect(isDateMoreRecentThan(aDate, otherDate, 60)).toBe(false); // considered equal here
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should correctly compare an exactly equal date', (): void => {
|
||||||
|
const aDate = new Date('2022-09-09T13:00:00');
|
||||||
|
const otherDate = new Date('2022-09-09T13:00:00');
|
||||||
|
expect(isDateMoreRecentThan(aDate, otherDate, 60)).toBe(false);
|
||||||
|
});
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,6 +1,31 @@
|
|||||||
|
/// returns false if the dates are equal within the `equalityToleranceInSeconds` number of seconds
|
||||||
|
/// otherwise returns true if `comparedDate` is after `date`
|
||||||
|
|
||||||
export function isDateMoreRecentThan(
|
export function isDateMoreRecentThan(
|
||||||
date: Readonly<Date>,
|
date: Readonly<Date>,
|
||||||
comparedDate: Readonly<Date>
|
comparedDate: Readonly<Date>,
|
||||||
|
equalityToleranceInSeconds = 0
|
||||||
): boolean {
|
): boolean {
|
||||||
|
if (equalityToleranceInSeconds > 0) {
|
||||||
|
const areDatesEqual = isDateEqualTo(
|
||||||
|
date,
|
||||||
|
comparedDate,
|
||||||
|
equalityToleranceInSeconds
|
||||||
|
);
|
||||||
|
|
||||||
|
return !areDatesEqual && date > comparedDate;
|
||||||
|
}
|
||||||
|
|
||||||
return date > comparedDate;
|
return date > comparedDate;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function isDateEqualTo(
|
||||||
|
date: Date,
|
||||||
|
otherDate: Date,
|
||||||
|
toleranceInSeconds: number
|
||||||
|
): boolean {
|
||||||
|
const timestamp = date.getTime();
|
||||||
|
const otherTimestamp = otherDate.getTime();
|
||||||
|
const deltaInSeconds = Math.abs(timestamp - otherTimestamp) / 1000;
|
||||||
|
return deltaInSeconds <= toleranceInSeconds;
|
||||||
|
}
|
||||||
|
|||||||
@@ -52,4 +52,5 @@ export interface IIssuesProcessorOptions {
|
|||||||
ignorePrUpdates: boolean | undefined;
|
ignorePrUpdates: boolean | undefined;
|
||||||
exemptDraftPr: boolean;
|
exemptDraftPr: boolean;
|
||||||
closeIssueReason: string;
|
closeIssueReason: string;
|
||||||
|
includeOnlyAssigned: boolean;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -88,7 +88,8 @@ function _getAndValidateArgs(): IIssuesProcessorOptions {
|
|||||||
ignoreIssueUpdates: _toOptionalBoolean('ignore-issue-updates'),
|
ignoreIssueUpdates: _toOptionalBoolean('ignore-issue-updates'),
|
||||||
ignorePrUpdates: _toOptionalBoolean('ignore-pr-updates'),
|
ignorePrUpdates: _toOptionalBoolean('ignore-pr-updates'),
|
||||||
exemptDraftPr: core.getInput('exempt-draft-pr') === 'true',
|
exemptDraftPr: core.getInput('exempt-draft-pr') === 'true',
|
||||||
closeIssueReason: core.getInput('close-issue-reason')
|
closeIssueReason: core.getInput('close-issue-reason'),
|
||||||
|
includeOnlyAssigned: core.getInput('include-only-assigned') === 'true'
|
||||||
};
|
};
|
||||||
|
|
||||||
for (const numberInput of [
|
for (const numberInput of [
|
||||||
|
|||||||
Reference in New Issue
Block a user