Skip to content

Commit f0f981f

Browse files
Address typos in scripts documentation strings (#8185)
DOC
1 parent 818d672 commit f0f981f

8 files changed

+20
-16
lines changed

scripts/cloud_funcs/README.md

+9-5
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
This directory contains the following Google Cloud Functions.
22

33
### `trigger_nightly`
4-
Programatically triggers a Cloud Build on master. This function is called by the Cloud Scheduler around 4am "America/New York" time every day (configurable via the Cloud Scheduler UI).
4+
5+
Programmatically triggers a Cloud Build on master. This function is called by the Cloud Scheduler around 4am "America/New York" time every day (configurable via the Cloud Scheduler UI).
56
You can also trigger the function manually via the Cloud UI.
67

78
Command to re-deploy:
9+
810
```sh
911
gcloud functions deploy nightly_tfjs \
1012
--runtime nodejs14 \
@@ -15,6 +17,7 @@ If a build was triggered by nightly, there is a substitution variable `_NIGHTLY=
1517
You can forward the substitution as the `NIGHTLY` environment variable so the scripts can use it, by specifying `env: ['NIGHTLY=$_NIGHTLY']` in `cloudbuild.yml`. E.g. `integration_tests/benchmarks/benchmark_cloud.sh` uses the `NIGHTLY` bit to always run on nightly.
1618

1719
### `send_email`
20+
1821
Sends an email and a chat message with the nightly build status. Every build sends a message to the `cloud-builds` topic with its build information. The `send_email` function is subscribed to that topic and ignores all builds (e.g. builds triggered by pull requests) **except** for the nightly build and sends an email to an internal mailing list with its build status around 4:40am.
1922

2023
Command to re-deploy:
@@ -28,6 +31,7 @@ gcloud functions deploy send_email \
2831
```
2932

3033
### `sync_reactnative`
34+
3135
Makes a request to browserStack to sync the current build of the tfjs-react-native integration app to browserstack. The app itself is stored in a GCP bucket. This needs to be done at least once every 30 days and is triggered via cloud scheduler via the `sync_reactnative` topic.
3236
Currently set to run weekly on Thursdays at 3AM.
3337

@@ -44,7 +48,7 @@ gcloud functions deploy sync_reactnative \
4448

4549
The pipeline looks like this:
4650

47-
1) At 4am, Cloud Scheduler writes to `nightly_tfjs` topic
48-
2) That triggers the `nightly_tfjs` function, which starts a build programatically
49-
3) That build runs and writes its status to `cloud-builds` topic
50-
4) That triggers the `send_email` function, which sends email and chat with the build status.
51+
1. At 4am, Cloud Scheduler writes to `nightly_tfjs` topic
52+
2. That triggers the `nightly_tfjs` function, which starts a build programmatically
53+
3. That build runs and writes its status to `cloud-builds` topic
54+
4. That triggers the `send_email` function, which sends email and chat with the build status.

scripts/generate_cloudbuild.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ interface CloudbuildStep {
3333
const CUSTOM_PROPS = new Set(['nightlyOnly', 'waitedForByPackages']);
3434
interface CustomCloudbuildStep extends CloudbuildStep {
3535
nightlyOnly?: boolean; // Only run during nightly tests
36-
waitedForByPackages?: boolean; // Other non-bazel pacakges `waitFor` this step
36+
waitedForByPackages?: boolean; // Other non-bazel packages `waitFor` this step
3737
}
3838

3939
function removeCustomProps(step: CustomCloudbuildStep): CloudbuildStep {

scripts/make-version.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ fs.writeFile(path.join(dirName, 'src/version.ts'), versionCode, err => {
4343
if (err) {
4444
throw new Error(`Could not save version file ${version}: ${err}`);
4545
}
46-
console.log(`Version file for version ${version} saved sucessfully.`);
46+
console.log(`Version file for version ${version} saved successfully.`);
4747
});
4848

4949
if (dirName === 'tfjs-converter') {
@@ -60,7 +60,7 @@ version = '${version}'
6060
throw new Error(`Could not save pip version file ${version}: ${err}`);
6161
}
6262
console.log(
63-
`Version file for pip version ${version} saved sucessfully.`);
63+
`Version file for pip version ${version} saved successfully.`);
6464
});
6565

6666
const buildFilename = path.join(dirName, '/python/BUILD.bazel');
@@ -74,6 +74,6 @@ version = '${version}'
7474
fs.writeFileSync(buildFilename, newValue, 'utf-8');
7575

7676
console.log(
77-
`pip version ${version} for BUILD.bazel file is updated sucessfully.`);
77+
`pip version ${version} for BUILD.bazel file is updated successfully.`);
7878
});
7979
}

scripts/publish-npm.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function setDifference<T>(a: Set<T>, b: Set<T>): Set<T> {
7777
const parser = new argparse.ArgumentParser();
7878
parser.addArgument('--git-protocol', {
7979
action: 'storeTrue',
80-
help: 'Use the git protocal rather than the http protocol when cloning repos.'
80+
help: 'Use the git protocol rather than the http protocol when cloning repos.'
8181
});
8282

8383
parser.addArgument('--registry', {

scripts/release-tfjs.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ async function main() {
225225
fs.writeFileSync(packageJsonPath, pkg);
226226

227227
// Update dependency versions of all package.json files found in the
228-
// package to use the new verison numbers (except ones in node_modules).
228+
// package to use the new version numbers (except ones in node_modules).
229229
const subpackages =
230230
$(`find ${
231231
packagePath} -name package.json -not -path \'*/node_modules/*\'`)
@@ -289,7 +289,7 @@ async function main() {
289289
'YARN_REGISTRY="https://registry.npmjs.org/" yarn publish-npm ' +
290290
'after you merge the PR.' +
291291
'Remember to delete the dev branch once PR is merged.' +
292-
'Please remeber to update the website once you have released ' +
292+
'Please remember to update the website once you have released ' +
293293
'a new package version.');
294294

295295
if (args.dry) {

scripts/release-util.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,7 @@ export async function getReleaseBranch(name: string): Promise<string> {
415415
Array.from(branchesStr.split(/\n/)).map(line => line.toString().trim());
416416

417417
// Find the latest matching branch, e.g. tfjs_1.7.1
418-
// It will not match temprary generated branches such as tfjs_1.7.1_phase0.
418+
// It will not match temporary generated branches such as tfjs_1.7.1_phase0.
419419
const exp = '^' + name + '_([^_]+)$';
420420
const regObj = new RegExp(exp);
421421
const maybeBranch = branches.find(branch => branch.match(regObj));

scripts/release.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ const parser = new argparse.ArgumentParser();
3838

3939
parser.addArgument('--git-protocol', {
4040
action: 'storeTrue',
41-
help: 'Use the git protocal rather than the http protocol when cloning repos.'
41+
help: 'Use the git protocol rather than the http protocol when cloning repos.'
4242
});
4343

4444
async function main() {
@@ -174,7 +174,7 @@ async function main() {
174174
`Please publish by running ` +
175175
`YARN_REGISTRY="https://registry.npmjs.org/" yarn publish-npm ` +
176176
`after you merge the PR.` +
177-
`Please remeber to update the website once you have released ` +
177+
`Please remember to update the website once you have released ` +
178178
'a new package version');
179179

180180
process.exit(0);

scripts/start_local_debugger_server.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ parser.addArgument('--port', {
118118
});
119119

120120
parser.addArgument('--version', {
121-
help: `The verison of the bundle. Default: ${DEFAULT_VERSION}`,
121+
help: `The version of the bundle. Default: ${DEFAULT_VERSION}`,
122122
defaultValue: DEFAULT_VERSION,
123123
type: 'string',
124124
});

0 commit comments

Comments
 (0)