Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Overhauled release scripts and docs (#18569)
* Overhauled release scripts and docs
- Loading branch information
Brian Vaughn
committed
Apr 10, 2020
1 parent
af1b039
commit 8e13f09
Showing
19 changed files
with
105 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
#!/usr/bin/env node | ||
|
||
'use strict'; | ||
|
||
const {tmpdir} = require('os'); | ||
const {join} = require('path'); | ||
const {getBuildInfo, handleError} = require('./utils'); | ||
|
||
// This script is an escape hatch! | ||
// It exists for special case manual builds. | ||
// The typical suggested release process is to create a "next" build from a CI artifact. | ||
// This build script is optimized for speed and simplicity. | ||
// It doesn't run all of the tests that the CI environment runs. | ||
// You're expected to run those manually before publishing a release. | ||
|
||
const addBuildInfoJSON = require('./build-release-locally-commands/add-build-info-json'); | ||
const buildArtifacts = require('./build-release-locally-commands/build-artifacts'); | ||
const confirmAutomatedTesting = require('./build-release-locally-commands/confirm-automated-testing'); | ||
const copyRepoToTempDirectory = require('./build-release-locally-commands/copy-repo-to-temp-directory'); | ||
const npmPackAndUnpack = require('./build-release-locally-commands/npm-pack-and-unpack'); | ||
const printPrereleaseSummary = require('./shared-commands/print-prerelease-summary'); | ||
const updateVersionNumbers = require('./build-release-locally-commands/update-version-numbers'); | ||
|
||
const run = async () => { | ||
try { | ||
const cwd = join(__dirname, '..', '..'); | ||
const { | ||
branch, | ||
checksum, | ||
commit, | ||
reactVersion, | ||
version, | ||
} = await getBuildInfo(); | ||
const tempDirectory = join(tmpdir(), `react-${commit}`); | ||
const params = { | ||
branch, | ||
checksum, | ||
commit, | ||
cwd, | ||
reactVersion, | ||
tempDirectory, | ||
version, | ||
}; | ||
|
||
await confirmAutomatedTesting(params); | ||
await copyRepoToTempDirectory(params); | ||
await updateVersionNumbers(params); | ||
await addBuildInfoJSON(params); | ||
await buildArtifacts(params); | ||
await npmPackAndUnpack(params); | ||
await printPrereleaseSummary(params, false); | ||
} catch (error) { | ||
handleError(error); | ||
} | ||
}; | ||
|
||
run(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters