aboutsummaryrefslogtreecommitdiffstats
path: root/packages/monorepo-scripts
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2018-10-18 21:46:33 +0800
committerGitHub <noreply@github.com>2018-10-18 21:46:33 +0800
commit4b95e3d6848832a06fde54b29d41d99b2a52f6ec (patch)
tree88801e5747f905b31060ebe3af7cc42a11878c34 /packages/monorepo-scripts
parent9e8bca69a8a1d3570e30a28f150c0bec3848a760 (diff)
parent392d3394438fdadf4e3b4201c493e3a2921d8380 (diff)
downloaddexon-0x-contracts-4b95e3d6848832a06fde54b29d41d99b2a52f6ec.tar.gz
dexon-0x-contracts-4b95e3d6848832a06fde54b29d41d99b2a52f6ec.tar.zst
dexon-0x-contracts-4b95e3d6848832a06fde54b29d41d99b2a52f6ec.zip
Merge pull request #1156 from 0xProject/feature/0x/npm-domain
Move package org from 0xproject to 0x
Diffstat (limited to 'packages/monorepo-scripts')
-rw-r--r--packages/monorepo-scripts/README.md4
-rw-r--r--packages/monorepo-scripts/package.json2
-rw-r--r--packages/monorepo-scripts/src/find_unused_dependencies.ts2
-rw-r--r--packages/monorepo-scripts/src/publish.ts8
-rw-r--r--packages/monorepo-scripts/src/publish_release_notes.ts2
-rw-r--r--packages/monorepo-scripts/src/test_installation.ts4
-rw-r--r--packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts4
-rw-r--r--packages/monorepo-scripts/src/utils/github_release_utils.ts2
8 files changed, 14 insertions, 14 deletions
diff --git a/packages/monorepo-scripts/README.md b/packages/monorepo-scripts/README.md
index d979e27dc..0673098b5 100644
--- a/packages/monorepo-scripts/README.md
+++ b/packages/monorepo-scripts/README.md
@@ -47,13 +47,13 @@ yarn install
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
```bash
-PKG=@0xproject/monorepo-scripts yarn build
+PKG=@0x/monorepo-scripts yarn build
```
Or continuously rebuild on change:
```bash
-PKG=@0xproject/monorepo-scripts yarn watch
+PKG=@0x/monorepo-scripts yarn watch
```
### Clean
diff --git a/packages/monorepo-scripts/package.json b/packages/monorepo-scripts/package.json
index 57e8bc147..3a783af9b 100644
--- a/packages/monorepo-scripts/package.json
+++ b/packages/monorepo-scripts/package.json
@@ -1,6 +1,6 @@
{
"private": true,
- "name": "@0xproject/monorepo-scripts",
+ "name": "@0x/monorepo-scripts",
"version": "1.0.11",
"engines": {
"node": ">=6.12"
diff --git a/packages/monorepo-scripts/src/find_unused_dependencies.ts b/packages/monorepo-scripts/src/find_unused_dependencies.ts
index 4bb4b7dc5..42b4b7890 100644
--- a/packages/monorepo-scripts/src/find_unused_dependencies.ts
+++ b/packages/monorepo-scripts/src/find_unused_dependencies.ts
@@ -7,7 +7,7 @@ import { constants } from './constants';
import { utils } from './utils/utils';
// For some reason, `depcheck` hangs on some packages. Add them here.
-const IGNORE_PACKAGES = ['@0xproject/sol-compiler'];
+const IGNORE_PACKAGES = ['@0x/sol-compiler'];
(async () => {
utils.log('*** NOTE: Not all deps listed here are actually not required. ***');
diff --git a/packages/monorepo-scripts/src/publish.ts b/packages/monorepo-scripts/src/publish.ts
index 646818c58..c1a6b9d7f 100644
--- a/packages/monorepo-scripts/src/publish.ts
+++ b/packages/monorepo-scripts/src/publish.ts
@@ -18,7 +18,7 @@ import { DocGenerateAndUploadUtils } from './utils/doc_generate_and_upload_utils
import { publishReleaseNotesAsync } from './utils/github_release_utils';
import { utils } from './utils/utils';
-const NPM_NAMESPACE = '@0xproject/';
+const NPM_NAMESPACE = '@0x/';
const TODAYS_TIMESTAMP = moment().unix();
async function confirmAsync(message: string): Promise<void> {
@@ -96,7 +96,7 @@ function getPackagesWithDocs(allUpdatedPackages: Package[]): Package[] {
const packagesWithDocPages = packagesWithDocPagesStringIfExist.split(' ');
const updatedPackagesWithDocPages: Package[] = [];
_.each(allUpdatedPackages, pkg => {
- const nameWithoutPrefix = pkg.packageJson.name.replace('@0xproject/', '');
+ const nameWithoutPrefix = pkg.packageJson.name.replace('@0x/', '');
if (_.includes(packagesWithDocPages, nameWithoutPrefix)) {
updatedPackagesWithDocPages.push(pkg);
}
@@ -110,7 +110,7 @@ async function generateAndUploadDocJsonsAsync(
shouldUploadDocs: boolean,
): Promise<void> {
for (const pkg of packagesWithDocs) {
- const nameWithoutPrefix = pkg.packageJson.name.replace('@0xproject/', '');
+ const nameWithoutPrefix = pkg.packageJson.name.replace('@0x/', '');
const docGenerateAndUploadUtils = new DocGenerateAndUploadUtils(nameWithoutPrefix, isStaging, shouldUploadDocs);
await docGenerateAndUploadUtils.generateAndUploadDocsAsync();
}
@@ -130,7 +130,7 @@ async function confirmDocPagesRenderAsync(packagesWithDocs: Package[]): Promise<
_.each(packagesWithDocs, pkg => {
const name = pkg.packageJson.name;
- const nameWithoutPrefix = _.startsWith(name, NPM_NAMESPACE) ? name.split('@0xproject/')[1] : name;
+ const nameWithoutPrefix = _.startsWith(name, NPM_NAMESPACE) ? name.split('@0x/')[1] : name;
const link = `${constants.stagingWebsite}/docs/${nameWithoutPrefix}`;
// tslint:disable-next-line:no-floating-promises
opn(link);
diff --git a/packages/monorepo-scripts/src/publish_release_notes.ts b/packages/monorepo-scripts/src/publish_release_notes.ts
index 6090498e0..297eb3d50 100644
--- a/packages/monorepo-scripts/src/publish_release_notes.ts
+++ b/packages/monorepo-scripts/src/publish_release_notes.ts
@@ -15,7 +15,7 @@ const args = yargs
'Space-separated list of packages to generated release notes for. If not supplied, it does all `Lerna updated` packages.',
type: 'string',
})
- .example('$0 --isDryRun true --packages "0x.js @0xproject/web3-wrapper"', 'Full usage example').argv;
+ .example('$0 --isDryRun true --packages "0x.js @0x/web3-wrapper"', 'Full usage example').argv;
(async () => {
const isDryRun = args.isDryRun;
diff --git a/packages/monorepo-scripts/src/test_installation.ts b/packages/monorepo-scripts/src/test_installation.ts
index 459f70839..96875d0f9 100644
--- a/packages/monorepo-scripts/src/test_installation.ts
+++ b/packages/monorepo-scripts/src/test_installation.ts
@@ -12,7 +12,7 @@ import { Package } from './types';
import { utils } from './utils/utils';
// Packages might not be runnable if they are command-line tools or only run in browsers.
-const UNRUNNABLE_PACKAGES = ['@0xproject/abi-gen', '@0xproject/react-shared', '@0xproject/react-docs'];
+const UNRUNNABLE_PACKAGES = ['@0x/abi-gen', '@0x/react-shared', '@0x/react-docs'];
const mkdirpAsync = promisify(mkdirp);
const rimrafAsync = promisify(rimraf);
@@ -116,7 +116,7 @@ async function testInstallPackageAsync(
await writeFileAsync(indexFilePath, `import * as Package from '${packageName}';\nconsole.log(Package);\n`);
const tsConfig = {
compilerOptions: {
- typeRoots: ['node_modules/@0xproject/typescript-typings/types', 'node_modules/@types'],
+ typeRoots: ['node_modules/@0x/typescript-typings/types', 'node_modules/@types'],
module: 'commonjs',
target: 'es5',
lib: ['es2017', 'dom'],
diff --git a/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts b/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
index 547b65eeb..1a4294e9c 100644
--- a/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
+++ b/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
@@ -402,7 +402,7 @@ export class DocGenerateAndUploadUtils {
sanitizedExportPathToExportPath[sanitizedExportPath] = exportPath;
return sanitizedExportPath;
}
- const monorepoPrefix = '@0xproject/';
+ const monorepoPrefix = '@0x/';
if (_.startsWith(exportPath, monorepoPrefix)) {
const sanitizedExportPath = exportPath.split(monorepoPrefix)[1];
sanitizedExportPathToExportPath[sanitizedExportPath] = exportPath;
@@ -478,7 +478,7 @@ export class DocGenerateAndUploadUtils {
});
});
- // @0xproject/types & ethereum-types are examples of packages where their index.ts exports types
+ // @0x/types & ethereum-types are examples of packages where their index.ts exports types
// directly, meaning no internal paths will exist to follow. Other packages also have direct exports
// in their index.ts, so we always add it to the source files passed to TypeDoc
if (typeDocSourceIncludes.size === 0) {
diff --git a/packages/monorepo-scripts/src/utils/github_release_utils.ts b/packages/monorepo-scripts/src/utils/github_release_utils.ts
index 0f3485de0..43c52ec2d 100644
--- a/packages/monorepo-scripts/src/utils/github_release_utils.ts
+++ b/packages/monorepo-scripts/src/utils/github_release_utils.ts
@@ -93,7 +93,7 @@ function adjustAssetPaths(assets: string[]): string[] {
}
function getReleaseNotesForPackage(packageName: string, version: string): string {
- const packageNameWithoutNamespace = packageName.replace('@0xproject/', '');
+ const packageNameWithoutNamespace = packageName.replace('@0x/', '');
const changelogJSONPath = path.join(
constants.monorepoRootPath,
'packages',