mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-20 10:29:36 -06:00
Small addition to user PR script to support fork/branch PRs
This commit is contained in:
parent
c1f2aba364
commit
0ddd847e03
@ -20,7 +20,7 @@ function padNum(number: number) {
|
||||
const userName = process.env.GH_USERNAME;
|
||||
const reviewers = ["weswigham", "sandersn", "RyanCavanaugh"]
|
||||
const now = new Date();
|
||||
const branchName = `user-update-${now.getFullYear()}${padNum(now.getMonth())}${padNum(now.getDay())}`;
|
||||
const branchName = `user-update-${process.env.TARGET_FORK}-${now.getFullYear()}${padNum(now.getMonth())}${padNum(now.getDay())}${process.env.TARGET_BRANCH ? "-" + process.env.TARGET_BRANCH : ""}`;
|
||||
const remoteUrl = `https://${process.argv[2]}@github.com/${userName}/TypeScript.git`;
|
||||
runSequence([
|
||||
["git", ["checkout", "."]], // reset any changes
|
||||
@ -43,7 +43,7 @@ gh.pulls.create({
|
||||
maintainer_can_modify: true,
|
||||
title: `🤖 User test baselines have changed`,
|
||||
head: `${userName}:${branchName}`,
|
||||
base: "master",
|
||||
base: process.env.TARGET_BRANCH || "master",
|
||||
body:
|
||||
`Please review the diff and merge if no changes are unexpected.
|
||||
You can view the build log [here](https://typescript.visualstudio.com/TypeScript/_build/index?buildId=${process.env.BUILD_BUILDID}&_a=summary).
|
||||
|
||||
@ -1 +1 @@
|
||||
Subproject commit 46971a8454761f1a11d8fde4d96ff8d29bc4e754
|
||||
Subproject commit 40bdb4eadabc9fbed7d83e3f26817a931c0763b6
|
||||
Loading…
x
Reference in New Issue
Block a user