Skip to content

Commit a620fca

Browse files
authored
Fix(script): schedule presubmit at same time and fix a typo in file name (#13418)
* fix(script): make the presubmit run at same time * fix(script): fix typo in file name
1 parent f91c0b7 commit a620fca

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

scripts/caretaking/write-presumbit-scheduler.js renamed to scripts/caretaking/write-presubmit-scheduler.js

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ const presubmitScript = `${process.env.MAT_PRESUBMIT_DIR}/material-presubmit.sh`
2424
/** Time to start presubmits. */
2525
const startTime = '9:30 pm';
2626

27-
/** Number of minutes between presubmit runs. */
28-
const intervalMinutes = 10;
29-
3027
/** Instead of querying github for PR numbers, manually provide the PR numbers to be presubmit */
3128
const explicitPullRequests = [];
3229

@@ -41,10 +38,6 @@ const githubSearchOptions = {
4138
/** END OF CONFIGURATION. */
4239

4340

44-
45-
/** Number of intervals that have scheduled tasks already. */
46-
let presubmitCount = 0;
47-
4841
if (explicitPullRequests.length) {
4942
writeScheduleScript(explicitPullRequests.map(n => ({number: n})));
5043
} else {
@@ -69,10 +62,7 @@ function writeScheduleScript(prs) {
6962
`cd ${localRepo} ; ` +
7063
`${presubmitScript} ${pr.number} --global 2>&1 > ${logDir}/pr-${pr.number}.txt ` +
7164
`)' | ` +
72-
`at ${startTime} today + ${intervalMinutes * presubmitCount} min ` +
73-
`\n`;
74-
75-
presubmitCount++;
65+
`at ${startTime} today \n`;
7666
}
7767

7868
fs.writeFileSync(path.join(localRepo, 'dist', 'schedule-presubmit.sh'), script, 'utf-8');

0 commit comments

Comments
 (0)