Move from using lerna multi-package commands to wsrun, update README's accordingly
This commit is contained in:
parent
c94d1b2275
commit
478f6ed011
@ -22,7 +22,7 @@ jobs:
|
||||
- run: wget https://s3.amazonaws.com/testrpc-shapshots/${CONTRACTS_COMMIT_HASH}.zip
|
||||
- run: unzip ${CONTRACTS_COMMIT_HASH}.zip -d testrpc_snapshot
|
||||
- run: node ./node_modules/lerna/bin/lerna.js bootstrap
|
||||
- run: yarn lerna:run build
|
||||
- run: yarn build
|
||||
- save_cache:
|
||||
key: repo-{{ .Environment.CIRCLE_SHA1 }}
|
||||
paths:
|
||||
@ -48,7 +48,7 @@ jobs:
|
||||
name: testrpc
|
||||
command: npm run testrpc -- --db testrpc_snapshot
|
||||
background: true
|
||||
- run: yarn lerna:run --scope 0x.js test:circleci
|
||||
- run: yarn wsrun test:circleci 0x.js
|
||||
- save_cache:
|
||||
key: coverage-0xjs-{{ .Environment.CIRCLE_SHA1 }}
|
||||
paths:
|
||||
@ -65,7 +65,7 @@ jobs:
|
||||
name: testrpc
|
||||
command: npm run testrpc -- --db testrpc_snapshot
|
||||
background: true
|
||||
- run: yarn lerna:run --scope contracts test:circleci
|
||||
- run: yarn wsrun test:circleci contracts
|
||||
- save_cache:
|
||||
key: coverage-contracts-{{ .Environment.CIRCLE_SHA1 }}
|
||||
paths:
|
||||
@ -82,7 +82,7 @@ jobs:
|
||||
name: testrpc
|
||||
command: npm run testrpc -- --db testrpc_snapshot
|
||||
background: true
|
||||
- run: yarn lerna:run --scope @0xproject/sol-compiler test:circleci
|
||||
- run: yarn wsrun test:circleci @0xproject/sol-compiler
|
||||
- save_cache:
|
||||
key: coverage-sol-compiler-{{ .Environment.CIRCLE_SHA1 }}
|
||||
paths:
|
||||
@ -99,7 +99,7 @@ jobs:
|
||||
name: testrpc
|
||||
command: npm run testrpc -- --db testrpc_snapshot
|
||||
background: true
|
||||
- run: yarn lerna:run --ignore contracts --ignore 0x.js --ignore @0xproject/sol-compiler test:circleci
|
||||
- run: yarn wsrun test:circleci --exclude contracts --exclude 0x.js --exclude @0xproject/sol-compiler --stages --exclude-missing
|
||||
- save_cache:
|
||||
key: coverage-assert-{{ .Environment.CIRCLE_SHA1 }}
|
||||
paths:
|
||||
@ -136,7 +136,7 @@ jobs:
|
||||
- restore_cache:
|
||||
keys:
|
||||
- repo-{{ .Environment.CIRCLE_SHA1 }}
|
||||
- run: yarn lerna:run lint
|
||||
- run: yarn wsrun lint --parallel --exclude-missing
|
||||
prettier:
|
||||
working_directory: ~/repo
|
||||
docker:
|
||||
|
73
README.md
73
README.md
@ -78,45 +78,86 @@ We strongly recommend that the community help us make improvements and determine
|
||||
### Install dependencies
|
||||
|
||||
If you don't have yarn workspaces enabled (Yarn < v1.0) - enable them:
|
||||
|
||||
```bash
|
||||
yarn config set workspaces-experimental true
|
||||
```
|
||||
|
||||
Then install dependencies
|
||||
|
||||
```bash
|
||||
yarn install
|
||||
```
|
||||
|
||||
### Build
|
||||
|
||||
Build all packages. You need to do this before working on any given package. Although these packages
|
||||
as independent, when run from within the monorepo, they are internally symlinked, to make development
|
||||
easier. You can change several packages and run the changes without publishing them first to NPM. When
|
||||
running `rebuild`, Lerna will figure out the dependency order of all the packages, and build them in
|
||||
this order.
|
||||
|
||||
To build all packages:
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
To build a specific package:
|
||||
```bash
|
||||
yarn dev
|
||||
PKG=@0xproject/web3-wrapper yarn build
|
||||
```
|
||||
|
||||
### Watch
|
||||
|
||||
To re-build all packages on change:
|
||||
```bash
|
||||
yarn watch
|
||||
```
|
||||
|
||||
To watch a specific package and all it's dependent packages:
|
||||
```bash
|
||||
PKG=[NPM_PACKAGE_NAME] yarn watch
|
||||
|
||||
e.g
|
||||
PKG=@0xproject/web3-wrapper yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
||||
Clean all packages:
|
||||
```bash
|
||||
yarn clean
|
||||
```
|
||||
|
||||
Clean a specific package
|
||||
```bash
|
||||
PKG=0x.js yarn clean
|
||||
```
|
||||
|
||||
### Rebuild
|
||||
|
||||
To re-build (clean & build) all packages:
|
||||
```bash
|
||||
yarn rebuild
|
||||
```
|
||||
|
||||
To re-build (clean & build) a specific package & it's deps:
|
||||
```bash
|
||||
PKG=0x.js yarn rebuild
|
||||
```
|
||||
|
||||
### Lint
|
||||
|
||||
Lint all packages
|
||||
|
||||
Lint all packages:
|
||||
```bash
|
||||
yarn lerna:run lint
|
||||
yarn lint
|
||||
```
|
||||
|
||||
Lint a specific package:
|
||||
```bash
|
||||
PKG=0x.js yarn lint
|
||||
```
|
||||
|
||||
### Run Tests
|
||||
|
||||
Run all tests:
|
||||
```bash
|
||||
yarn lerna:test
|
||||
yarn test
|
||||
```
|
||||
|
||||
Run a specific package's test:
|
||||
```bash
|
||||
PKG=@0xproject/web3-wrapper yarn test
|
||||
```
|
||||
|
26
package.json
26
package.json
@ -5,23 +5,24 @@
|
||||
"packages/*"
|
||||
],
|
||||
"scripts": {
|
||||
"dev": "lerna run --parallel build:watch",
|
||||
"testrpc": "testrpc -p 8545 --networkId 50 -m \"${npm_package_config_mnemonic}\"",
|
||||
"prettier": "prettier --write '**/*.{ts,tsx,json,md}' --config .prettierrc",
|
||||
"prettier:ci": "prettier --list-different '**/*.{ts,tsx,json,md}' --config .prettierrc",
|
||||
"report_coverage": "lcov-result-merger 'packages/*/coverage/lcov.info' | coveralls",
|
||||
"test:installation": "node ./packages/monorepo-scripts/lib/test_installation.js",
|
||||
"lerna:install": "yarn install",
|
||||
"lerna:run": "lerna run",
|
||||
"lerna:test": "lerna run test",
|
||||
"lerna:clean": "lerna run clean",
|
||||
"lerna:build": "lerna run build",
|
||||
"lerna:rebuild": "run-s lerna:clean lerna:build",
|
||||
"lerna:publish": "run-s lerna:install lerna:rebuild script:publish",
|
||||
"lerna:publish:dry": "run-s lerna:install lerna:rebuild script:publish:dry",
|
||||
"lerna:stage_docs": "lerna run docs:stage",
|
||||
"publish": "run-s install rebuild script:publish",
|
||||
"publish:dry": "run-s install rebuild script:publish:dry",
|
||||
"script:publish": "node ./packages/monorepo-scripts/lib/publish.js",
|
||||
"script:publish:dry": "IS_DRY_RUN=true yarn script:publish"
|
||||
"script:publish:dry": "IS_DRY_RUN=true yarn script:publish",
|
||||
"install": "yarn install",
|
||||
"wsrun": "wsrun",
|
||||
"watch": "wsrun watch $PKG -r --stages --done-criteria='complete|successfully'",
|
||||
"build": "wsrun build $PKG -r --stages",
|
||||
"clean": "wsrun clean $PKG -r --parallel",
|
||||
"rebuild": "run-s clean build",
|
||||
"test": "wsrun test $PKG --serial --exclude-missing",
|
||||
"stage_docs": "wsrun docs:stage $PKG --parallel --exclude-missing",
|
||||
"lint": "wsrun lint $PKG --parallel --exclude-missing"
|
||||
},
|
||||
"config": {
|
||||
"mnemonic": "concert load couple harbor equip island argue ramp clarify fence smart topic"
|
||||
@ -33,6 +34,7 @@
|
||||
"lcov-result-merger": "^2.0.0",
|
||||
"lerna": "^2.5.1",
|
||||
"npm-run-all": "^4.1.2",
|
||||
"prettier": "^1.11.1"
|
||||
"prettier": "^1.11.1",
|
||||
"wsrun": "^2.2.0"
|
||||
}
|
||||
}
|
||||
|
@ -64,28 +64,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=0x.js yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=0x.js yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -12,7 +12,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean generate_contract_wrappers",
|
||||
"build": "run-p build:umd:prod build:commonjs; exit 0;",
|
||||
"generate_contract_wrappers": "node ../abi-gen/lib/index.js --abis 'src/compact_artifacts/@(Exchange|Token|TokenTransferProxy|EtherToken|TokenRegistry|DummyToken).json' --template ../contract_templates/contract.handlebars --partials '../contract_templates/partials/**/*.handlebars' --output src/contract_wrappers/generated --backend ethers && prettier --write 'src/contract_wrappers/generated/**.ts'",
|
||||
|
@ -80,28 +80,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/abi-gen yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/abi-gen yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"lint": "tslint --project .",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
|
@ -46,28 +46,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/assert yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/assert yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib test_temp scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -44,14 +44,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
PKG=@0xproject/base-contract yarn build
|
||||
```
|
||||
|
||||
or
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/base-contract yarn watch
|
||||
```
|
||||
|
||||
### Lint
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"test": "run-s clean build run_mocha",
|
||||
|
@ -43,28 +43,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/connect yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/connect yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -12,7 +12,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib test_temp scripts",
|
||||
"copy_test_fixtures": "copyfiles -u 2 './test/fixtures/**/*.json' ./lib/test/fixtures",
|
||||
|
@ -48,19 +48,19 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/contract-wrappers yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
PKG=@0xproject/contract-wrappers yarn watch
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
@ -69,7 +69,7 @@ yarn build
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -11,7 +11,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean generate_contract_wrappers",
|
||||
"generate_contract_wrappers": "node ../abi-gen/lib/index.js --abis 'src/compact_artifacts/@(Exchange|Token|TokenTransferProxy|EtherToken|TokenRegistry|DummyToken).json' --template ../contract_templates/contract.handlebars --partials '../contract_templates/partials/**/*.handlebars' --output src/contract_wrappers/generated --backend ethers && prettier --write 'src/contract_wrappers/generated/**.ts'",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -34,28 +34,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=contracts yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=contracts yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -8,7 +8,7 @@
|
||||
"test": "test"
|
||||
},
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean copy_artifacts generate_contract_wrappers",
|
||||
"copy_artifacts": "copyfiles -u 4 '../migrations/artifacts/1.0.0/**/*' ./lib/src/artifacts;",
|
||||
"build": "tsc",
|
||||
|
@ -49,28 +49,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/dev-utils yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/dev-utils yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"test": "run-s clean build run_mocha",
|
||||
"test:circleci": "yarn test:coverage",
|
||||
|
@ -38,28 +38,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/fill-scenarios yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/fill-scenarios yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean generate_contract_wrappers",
|
||||
"generate_contract_wrappers": "node ../abi-gen/lib/index.js --abis 'src/compact_artifacts/@(Exchange|Token|TokenTransferProxy|EtherToken|DummyToken).json' --template ../contract_templates/contract.handlebars --partials '../contract_templates/partials/**/*.handlebars' --output src/generated_contract_wrappers --backend ethers && prettier --write 'src/generated_contract_wrappers/**.ts'",
|
||||
"build": "tsc && copyfiles -u 2 './src/compact_artifacts/**/*.json' ./lib/compact_artifacts && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
|
@ -52,28 +52,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/json-schemas yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/json-schemas yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"lint": "tslint --project .",
|
||||
"test": "run-s clean build run_mocha",
|
||||
"test:coverage": "nyc npm run test --all && yarn coverage:report:lcov",
|
||||
|
@ -4,7 +4,7 @@
|
||||
"private": true,
|
||||
"description": "Example solidity project using 0x dev tools",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"lint": "tslint --project .",
|
||||
"clean": "shx rm -rf lib artifacts src/contract_wrappers",
|
||||
"prebuild": "run-s clean compile generate_contract_wrappers copy_artifacts",
|
||||
|
@ -24,28 +24,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/migrations yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/migrations yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean compile copy_artifacts generate_contract_wrappers",
|
||||
"copy_artifacts": "copyfiles -u 4 'artifacts/1.0.0/**/*' ./lib/src/artifacts",
|
||||
"build": "tsc",
|
||||
|
@ -4,7 +4,7 @@ This repository contains a few helpful scripts for working with this mono repo.
|
||||
|
||||
#### Scripts
|
||||
|
||||
**`yarn deps_versions`**: Since we use Lerna + Yarn workspaces, shared dependencies between packages in the monorepo get hoisted to a top-level `node_modules` directory. If two packages use different versions of the same dependency however, both get installed. To avoid having many versions of a dependency installed, we try to keep dependency versions the same across packages in the monorepo. This script will list any dependencies for which we have multiple versions installed. We can then go through them and try to consolidate to a single version where possible.
|
||||
**`yarn deps_versions`**: Since we are a Yarn workspaces monorepo, shared dependencies between packages in the monorepo get hoisted to a top-level `node_modules` directory. If two packages use different versions of the same dependency however, both get installed. To avoid having many versions of a dependency installed, we try to keep dependency versions the same across packages in the monorepo. This script will list any dependencies for which we have multiple versions installed. We can then go through them and try to consolidate to a single version where possible.
|
||||
|
||||
**`yarn find_unused_deps`**: Sometimes we accidentally leave dependencies listed in `package.json` that are no longer being used. This script finds potential dependencies that might no longer be in use. Please verify that it is no longer in use before removing, the `depcheck` package we use under-the-hood doesn't handle some TS quirks perfectly.
|
||||
|
||||
@ -46,28 +46,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/monorepo-scripts yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/monorepo-scripts yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"lint": "tslint --project .",
|
||||
"clean": "shx rm -rf lib",
|
||||
"build": "tsc",
|
||||
@ -26,7 +26,6 @@
|
||||
"url": "https://github.com/0xProject/0x-monorepo/issues"
|
||||
},
|
||||
"homepage": "https://github.com/0xProject/0x-monorepo/packages/monorepo-scripts/README.md",
|
||||
"comment": "// We purposefully use an older version of tslint-config here to avoid creating an import cycle",
|
||||
"devDependencies": {
|
||||
"@types/glob": "^5.0.33",
|
||||
"@types/node": "^8.0.53",
|
||||
|
@ -75,7 +75,7 @@ const packageNameToWebsitePath: { [name: string]: string } = {
|
||||
async function confirmDocPagesRenderAsync(packages: LernaPackage[]) {
|
||||
// push docs to staging
|
||||
utils.log("Upload all docJson's to S3 staging...");
|
||||
await execAsync(`yarn lerna:stage_docs`, { cwd: constants.monorepoRootPath });
|
||||
await execAsync(`yarn stage_docs`, { cwd: constants.monorepoRootPath });
|
||||
|
||||
// deploy website to staging
|
||||
utils.log('Deploy website to staging...');
|
||||
|
@ -40,28 +40,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/order-utils yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/order-utils yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"test": "run-s clean build run_mocha",
|
||||
"test:circleci": "yarn test:coverage",
|
||||
|
@ -48,28 +48,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/order-watcher yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/order-watcher yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -12,7 +12,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"prebuild": "run-s clean generate_contract_wrappers",
|
||||
"generate_contract_wrappers": "node ../abi-gen/lib/index.js --abis 'src/compact_artifacts/@(Exchange|Token|TokenTransferProxy|EtherToken).json' --template ../contract_templates/contract.handlebars --partials '../contract_templates/partials/**/*.handlebars' --output src/generated_contract_wrappers --backend ethers && prettier --write 'src/generated_contract_wrappers/**.ts'",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -25,7 +25,7 @@ yarn install
|
||||
The **first** time you work with this package, you must build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=0x.js yarn build
|
||||
```
|
||||
|
||||
Note: If you move this package out of the monorepo, it will work without this step. Make sure you copy it out on the `master` branch since the `development` version might rely on not-yet published changes to other packages.
|
||||
@ -35,7 +35,7 @@ Note: If you move this package out of the monorepo, it will work without this st
|
||||
The the `react-docs-example` root directory, run:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
PKG=0x.js yarn watch
|
||||
```
|
||||
|
||||
### Deploy Example to S3 bucket
|
||||
@ -50,8 +50,16 @@ yarn deploy_example
|
||||
|
||||
### Build
|
||||
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
PKG=@0xproject/react-docs-example yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
PKG=@0xproject/react-docs-example yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -7,7 +7,7 @@
|
||||
"lint": "tslint --project .",
|
||||
"build": "tsc",
|
||||
"build:example": "NODE_ENV=production webpack",
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"clean": "shx rm -rf lib; shx rm -f public/bundle*",
|
||||
"dev": "webpack-dev-server --open",
|
||||
"deploy_example": "npm run build:example; aws s3 sync ./public/. s3://react-docs-example --profile 0xproject --region us-east-1 --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers"
|
||||
|
@ -71,28 +71,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/react-docs yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/react-docs yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -7,7 +7,7 @@
|
||||
"scripts": {
|
||||
"lint": "tslint --project .",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"manual:postpublish": "yarn build; node ./scripts/postpublish.js"
|
||||
},
|
||||
|
@ -38,28 +38,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/react-shared yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/react-shared yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -7,7 +7,7 @@
|
||||
"scripts": {
|
||||
"lint": "tslint --project .",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"manual:postpublish": "yarn build; node ./scripts/postpublish.js"
|
||||
},
|
||||
|
@ -60,28 +60,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/sol-compiler yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/sol-compiler yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "yarn clean && copyfiles 'test/fixtures/contracts/**/*' ./lib && tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"test": "run-s build run_mocha",
|
||||
"run_mocha": "mocha lib/test/*_test.js --bail --exit",
|
||||
|
@ -44,28 +44,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/sol-cov yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/sol-cov yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"lint": "tslint --project .",
|
||||
"test": "run-s clean build compile_test run_mocha",
|
||||
"test:coverage": "nyc npm run test --all && yarn coverage:report:lcov",
|
||||
|
67
packages/sol-resolver/README.md
Normal file
67
packages/sol-resolver/README.md
Normal file
@ -0,0 +1,67 @@
|
||||
## @0xproject/sol-resolver
|
||||
|
||||
A Solidity import resolver used by [sol-compiler](https://github.com/0xProject/0x-monorepo/tree/development/packages/sol-compiler).
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
yarn add @0xproject/sol-resolver
|
||||
```
|
||||
|
||||
**Import**
|
||||
|
||||
```javascript
|
||||
import { Resolver } from '@0xproject/sol-resolver';
|
||||
```
|
||||
|
||||
or
|
||||
|
||||
```javascript
|
||||
var Resolver = require('@0xproject/sol-resolver').Resolver;
|
||||
```
|
||||
|
||||
## Contributing
|
||||
|
||||
We welcome improvements and fixes from the wider community! To report bugs within this package, please create an issue in this repository.
|
||||
|
||||
Please read our [contribution guidelines](../../CONTRIBUTING.md) before getting started.
|
||||
|
||||
### Install dependencies
|
||||
|
||||
If you don't have yarn workspaces enabled (Yarn < v1.0) - enable them:
|
||||
|
||||
```bash
|
||||
yarn config set workspaces-experimental true
|
||||
```
|
||||
|
||||
Then install dependencies
|
||||
|
||||
```bash
|
||||
yarn install
|
||||
```
|
||||
|
||||
### Build
|
||||
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
PKG=@0xproject/sol-resolver yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
PKG=@0xproject/sol-resolver yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
||||
```bash
|
||||
yarn clean
|
||||
```
|
||||
|
||||
### Lint
|
||||
|
||||
```bash
|
||||
yarn lint
|
||||
```
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "yarn clean && tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -107,28 +107,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/sra-report yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/sra-report yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/src/index.js",
|
||||
"types": "lib/src/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -42,28 +42,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/subproviders yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/subproviders yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"types": "lib/src/index.d.ts",
|
||||
"license": "Apache-2.0",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -28,28 +28,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/testnet-faucets yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/testnet-faucets yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
@ -86,7 +74,7 @@ Infura API Key can be requested here: https://infura.io/signup
|
||||
Note: The above public/private keys exist when running `testrpc` with the following option `--mnemonic concert load couple harbor equip island argue ramp clarify fence smart topic`.
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
PKG=0x.js yarn watch
|
||||
```
|
||||
|
||||
### Endpoints
|
||||
|
@ -5,7 +5,7 @@
|
||||
"description": "A faucet micro-service that dispenses test ERC20 tokens or Ether",
|
||||
"main": "server.js",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "node ../../node_modules/gulp/bin/gulp.js build",
|
||||
"dev": "node ../../node_modules/gulp/bin/gulp.js run",
|
||||
"start": "node ./bin/server.js",
|
||||
|
@ -40,28 +40,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/tslint-config yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/tslint-config yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -4,7 +4,7 @@
|
||||
"description": "Lint rules related to 0xProject for TSLint",
|
||||
"main": "tslint.json",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -44,28 +44,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/types yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/types yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -40,28 +40,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/typescript-typings yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/typescript-typings yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -3,6 +3,7 @@
|
||||
"version": "0.3.1",
|
||||
"description": "0x project typescript type definitions",
|
||||
"scripts": {
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 1 './lib/**/*' ./scripts",
|
||||
"clean": "shx rm -rf scripts",
|
||||
"manual:postpublish": "yarn build; node ./scripts/postpublish.js"
|
||||
|
@ -44,28 +44,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/utils yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/utils yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -5,7 +5,7 @@
|
||||
"main": "lib/index.js",
|
||||
"types": "lib/index.d.ts",
|
||||
"scripts": {
|
||||
"build:watch": "tsc -w",
|
||||
"watch": "tsc -w",
|
||||
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
|
||||
"clean": "shx rm -rf lib scripts",
|
||||
"lint": "tslint --project .",
|
||||
|
@ -40,28 +40,16 @@ yarn install
|
||||
|
||||
### Build
|
||||
|
||||
If this is your **first** time building this package, you must first build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/web3-wrapper yarn build
|
||||
```
|
||||
|
||||
Or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
```
|
||||
|
||||
You can also build this specific package by running the following from within its directory:
|
||||
|
||||
```bash
|
||||
yarn build
|
||||
```
|
||||
|
||||
or continuously rebuild on change:
|
||||
|
||||
```bash
|
||||
yarn build:watch
|
||||
PKG=@0xproject/web3-wrapper yarn watch
|
||||
```
|
||||
|
||||
### Clean
|
||||
|
@ -30,18 +30,16 @@ yarn install
|
||||
|
||||
### Initial setup
|
||||
|
||||
The **first** time you work with this package, you must build **all** packages within the monorepo. This is because packages that depend on other packages located inside this monorepo are symlinked when run from **within** the monorepo. This allows you to make changes across multiple packages without first publishing dependent packages to NPM. To build all packages, run the following from the monorepo root directory:
|
||||
To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:
|
||||
|
||||
```bash
|
||||
yarn lerna:rebuild
|
||||
PKG=@0xproject/website yarn build
|
||||
```
|
||||
|
||||
### Run dev server
|
||||
|
||||
The the `website` root directory, run:
|
||||
|
||||
```bash
|
||||
yarn dev
|
||||
PKG=@0xproject/website yarn watch
|
||||
```
|
||||
|
||||
Visit [0xproject.localhost:3572](http://0xproject.localhost:3572) in your browser.
|
||||
|
@ -7,7 +7,7 @@
|
||||
"build": "NODE_ENV=production webpack; exit 0;",
|
||||
"clean": "shx rm -f public/bundle*",
|
||||
"lint": "tslint --project . 'ts/**/*.ts' 'ts/**/*.tsx'",
|
||||
"dev": "webpack-dev-server --content-base public --https",
|
||||
"watch": "webpack-dev-server --content-base public --https",
|
||||
"deploy_staging": "npm run build; aws s3 sync ./public/. s3://staging-0xproject --profile 0xproject --region us-east-1 --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers",
|
||||
"deploy_live": "npm run build; aws s3 sync ./public/. s3://0xproject.com --profile 0xproject --region us-east-1 --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers"
|
||||
},
|
||||
|
27
yarn.lock
27
yarn.lock
@ -6,15 +6,6 @@
|
||||
version "0.3.9"
|
||||
resolved "https://registry.yarnpkg.com/8fold-marked/-/8fold-marked-0.3.9.tgz#bb89c645612f8ccfaffac1ca6e3c11f168c9cf59"
|
||||
|
||||
"@0xproject/tslint-config@0.4.13":
|
||||
version "0.4.13"
|
||||
resolved "https://registry.yarnpkg.com/@0xproject/tslint-config/-/tslint-config-0.4.13.tgz#98c71c5ae5e80315a23eda0134cc9f6f4438cac2"
|
||||
dependencies:
|
||||
lodash "^4.17.4"
|
||||
tslint "5.8.0"
|
||||
tslint-eslint-rules "^4.1.1"
|
||||
tslint-react "^3.2.0"
|
||||
|
||||
"@0xproject/types@^0.5.0":
|
||||
version "0.5.0"
|
||||
resolved "https://registry.yarnpkg.com/@0xproject/types/-/types-0.5.0.tgz#ba3cfbc11a8c6344b57c9680aa7df2ea84b9bf05"
|
||||
@ -9875,7 +9866,7 @@ split@0.3:
|
||||
dependencies:
|
||||
through "2"
|
||||
|
||||
split@^1.0.0:
|
||||
split@^1.0.0, split@^1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/split/-/split-1.0.1.tgz#605bd9be303aa59fb35f9229fbea0ddec9ea07d9"
|
||||
dependencies:
|
||||
@ -10373,6 +10364,10 @@ thenify-all@^1.0.0, thenify-all@^1.6.0:
|
||||
dependencies:
|
||||
any-promise "^1.0.0"
|
||||
|
||||
throat@^4.1.0:
|
||||
version "4.1.0"
|
||||
resolved "https://registry.yarnpkg.com/throat/-/throat-4.1.0.tgz#89037cbc92c56ab18926e6ba4cbb200e15672a6a"
|
||||
|
||||
through2-filter@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-2.0.0.tgz#60bc55a0dacb76085db1f9dae99ab43f83d622ec"
|
||||
@ -11784,6 +11779,18 @@ ws@^5.1.1:
|
||||
dependencies:
|
||||
async-limiter "~1.0.0"
|
||||
|
||||
wsrun@^2.2.0:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/wsrun/-/wsrun-2.2.0.tgz#fe05ca2c466e9281059d255b2773e7964dbcb3a7"
|
||||
dependencies:
|
||||
bluebird "^3.5.1"
|
||||
chalk "^2.3.0"
|
||||
glob "^7.1.2"
|
||||
lodash "^4.17.4"
|
||||
split "^1.0.1"
|
||||
throat "^4.1.0"
|
||||
yargs "^10.0.3"
|
||||
|
||||
x-is-function@^1.0.4:
|
||||
version "1.0.4"
|
||||
resolved "https://registry.yarnpkg.com/x-is-function/-/x-is-function-1.0.4.tgz#5d294dc3d268cbdd062580e0c5df77a391d1fa1e"
|
||||
|
Loading…
x
Reference in New Issue
Block a user