Skip to content

Commit a8c50db

Browse files
committed
add comments
1 parent 8a49d6c commit a8c50db

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

scripts/exp/prepare-firestore-for-exp-release.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,18 @@ const writeFile = promisify(_writeFile);
2424
const readFile = promisify(_readFile);
2525
const packagePath = `${projectRoot}/packages/firestore`;
2626

27-
// Prepare @firebase/firestore, so scripts/exp/release.ts can be used to release it
27+
//
28+
/**
29+
* Transform package.json in @firebase/firestore so that we can use scripts/exp/release.ts to release Firestore exp.
30+
* It does following things:
31+
* 1. Update package.json to point to exp binaries
32+
* 2. Update version to '0.0.800', the version number we choose for releasing exp packages
33+
* (8 stands for v8, 800 to avoid conflict with official versions).
34+
* The release script will append commit hash to it and release the package with that version.
35+
* e.g. 0.0.800-exp.fe85035e1
36+
* 3. Replace peerDependencies with the exp version, so the release script can match and update them to the correct version.
37+
* 4. Replace imports with imports from exp packages in typing files.
38+
*/
2839
export async function prepare() {
2940
// Update package.json
3041
const packageJson = await readPackageJson(packagePath);

0 commit comments

Comments
 (0)