Skip to content
This repository has been archived by the owner on Jul 9, 2021. It is now read-only.

Commit

Permalink
Merge branch 'development' of https://github.com/0xProject/0x-monorepo
Browse files Browse the repository at this point in the history
…into feature/instant/move-features-over-from-zrx-buyer
  • Loading branch information
fragosti committed Oct 16, 2018
2 parents d268e19 + 72f5719 commit dbf5be6
Show file tree
Hide file tree
Showing 338 changed files with 14,530 additions and 47,248 deletions.
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
*.sol linguist-language=Solidity

# Automatically collapse generated files in GitHub.
packages/contract-artifacts/artifacts/*json linguist-generated
packages/abi-gen-wrappers/wrappers/*.ts liguist-generated
26 changes: 5 additions & 21 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -79,30 +79,14 @@ packages/react-docs/example/public/bundle*
packages/testnet-faucets/server/

# generated contract artifacts/
packages/contracts/generated-artifacts/
packages/sol-cov/test/fixtures/artifacts/
packages/metacoin/artifacts/
packages/order-watcher/test/artifacts/
packages/contract-wrappers/test/artifacts/
packages/contract-wrappers/src/artifacts/
packages/order-watcher/src/artifacts/
packages/0x.js/src/artifacts/
packages/order-utils/src/artifacts/

# unstable generated contract artifacts:
packages/migrations/artifacts/development/

# generated contract watcher
packages/0x.js/src/generated_contract_wrappers/
packages/contracts/generated_contract_wrappers/
packages/contract-wrappers/src/contract_wrappers/generated/

# generated contract wrappers
packages/abi-gen-wrappers/wrappers
packages/contracts/generated-wrappers/
packages/metacoin/src/contract_wrappers
packages/fill-scenarios/src/generated_contract_wrappers/
packages/order-watcher/src/generated_contract_wrappers/
packages/order-utils/src/generated_contract_wrappers/
packages/migrations/src/1.0.0/contract_wrappers
packages/migrations/src/2.0.0-testnet/contract_wrappers
packages/migrations/src/2.0.0/contract_wrappers
packages/migrations/src/development/contract_wrappers

# solc-bin in sol-compiler
packages/sol-compiler/solc_bin/
Expand Down
23 changes: 4 additions & 19 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,27 +1,12 @@
lib
.nyc_output
/packages/contract-wrappers/src/contract_wrappers/generated/
/packages/contracts/generated-wrappers
/packages/contracts/generated-artifacts
/packages/abi-gen-wrappers/src/generated-wrappers
/packages/contract-artifacts/artifacts
/packages/metacoin/src/contract_wrappers
/packages/0x.js/src/generated_contract_wrappers/
/packages/contracts/generated_contract_wrappers/
/packages/fill-scenarios/src/generated_contract_wrappers/
/packages/order-watcher/src/generated_contract_wrappers/
/packages/order-utils/src/generated_contract_wrappers/
/packages/migrations/src/1.0.0/contract_wrappers
/packages/migrations/src/2.0.0-testnet/contract_wrappers
/packages/migrations/src/2.0.0/contract_wrappers
/packages/0x.js/src/artifacts
/packages/contracts/src/artifacts
/packages/contract-wrappers/src/artifacts
/packages/order-watcher/src/artifacts
/packages/metacoin/artifacts
/packages/sra-spec/public/
/packages/contract-wrappers/test/artifacts
/packages/order-watcher/test/artifacts
/packages/migrations/artifacts/1.0.0
/packages/migrations/artifacts/2.0.0-testnet
/packages/migrations/artifacts/2.0.0
/packages/migrations/artifacts/development
package.json
scripts/postpublish_utils.js
packages/sol-cov/test/fixtures/artifacts
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"report_coverage": "lcov-result-merger './{packages/*/coverage/lcov.info,python-packages/*/.coverage}' | coveralls",
"test:installation": "node ./packages/monorepo-scripts/lib/test_installation.js",
"test:installation:local": "IS_LOCAL_PUBLISH=true node ./packages/monorepo-scripts/lib/test_installation.js",
"test:publish:circleci:comment": "HACK(albrow) We need an automated way to login to npm and echo+sleep piped to stdin was the only way I could find to do it.",
"test:publish:circleci": "yarn npm-cli-login -u test -p test -e [email protected] -r http://localhost:4873 && IS_LOCAL_PUBLISH=true run-s script:publish test:installation:local",
"run:publish": "run-s install:all build:monorepo_scripts script:prepublish_checks rebuild:no_website script:publish",
"run:publish:local": "IS_LOCAL_PUBLISH=true yarn run:publish",
Expand Down
9 changes: 9 additions & 0 deletions packages/0x.js/CHANGELOG.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,15 @@
"note":
"Removed `SignerType` (including `SignerType.Metamask`). Please use the `MetamaskSubprovider` to wrap `web3.currentProvider`.",
"pr": 1102
},
{
"note":
"Updated to use new modularized artifacts and the latest version of @0xproject/contract-wrappers",
"pr": 1105
},
{
"note": "Make web3-provider-engine types a 'dependency' so it's available to users of the library",
"pr": 1105
}
]
},
Expand Down
4 changes: 3 additions & 1 deletion packages/0x.js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@
},
"license": "Apache-2.0",
"devDependencies": {
"@0xproject/contract-addresses": "^1.0.0",
"@0xproject/abi-gen": "^1.0.13",
"@0xproject/abi-gen-wrappers": "^1.0.0",
"@0xproject/dev-utils": "^1.0.12",
"@0xproject/migrations": "^1.0.14",
"@0xproject/monorepo-scripts": "^1.0.11",
Expand All @@ -51,7 +53,6 @@
"@types/mocha": "^2.2.42",
"@types/node": "*",
"@types/sinon": "^2.2.2",
"@types/web3-provider-engine": "^14.0.0",
"awesome-typescript-loader": "^5.2.1",
"chai": "^4.0.1",
"chai-as-promised": "^7.1.0",
Expand Down Expand Up @@ -83,6 +84,7 @@
"@0xproject/typescript-typings": "^3.0.2",
"@0xproject/utils": "^2.0.2",
"@0xproject/web3-wrapper": "^3.0.3",
"@types/web3-provider-engine": "^14.0.0",
"ethereum-types": "^1.0.11",
"ethers": "~4.0.4",
"lodash": "^4.17.5",
Expand Down
6 changes: 0 additions & 6 deletions packages/0x.js/src/globals.d.ts

This file was deleted.

23 changes: 14 additions & 9 deletions packages/0x.js/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
export { ContractAddresses } from '@0xproject/contract-addresses';

export { assetDataUtils, signatureUtils, generatePseudoRandomSalt, orderHashUtils } from '@0xproject/order-utils';

export {
Expand All @@ -18,6 +20,16 @@ export {
TransactionOpts,
OrderStatus,
OrderInfo,
EventCallback,
DecodedLogEvent,
TransactionEncoder,
BalanceAndAllowance,
OrderAndTraderInfo,
TraderInfo,
ValidateOrderFillableOpts,
} from '@0xproject/contract-wrappers';

export {
WETH9Events,
WETH9WithdrawalEventArgs,
WETH9ApprovalEventArgs,
Expand All @@ -38,16 +50,9 @@ export {
ExchangeSignatureValidatorApprovalEventArgs,
ExchangeFillEventArgs,
ExchangeCancelEventArgs,
ExchangeEvents,
EventCallback,
DecodedLogEvent,
ExchangeEventArgs,
TransactionEncoder,
BalanceAndAllowance,
OrderAndTraderInfo,
TraderInfo,
ValidateOrderFillableOpts,
} from '@0xproject/contract-wrappers';
ExchangeEvents,
} from '@0xproject/abi-gen-wrappers';

export { OrderWatcher, OnOrderStateChangeCallback, OrderWatcherConfig } from '@0xproject/order-watcher';

Expand Down
2 changes: 1 addition & 1 deletion packages/0x.js/typedoc-tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
"compilerOptions": {
"outDir": "lib"
},
"include": ["./src/**/*", "./test/**/*"]
"include": ["./src/**/*"]
}
11 changes: 11 additions & 0 deletions packages/abi-gen-wrappers/CHANGELOG.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[
{
"version": "1.0.0",
"changes": [
{
"pr": 1105,
"note": "Initial release"
}
]
}
]
73 changes: 73 additions & 0 deletions packages/abi-gen-wrappers/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
## @0xproject/abi-gen-wrappers

Low-level 0x smart contract wrappers generated using @0xproject/abi-gen. These
low-level wrappers are imported by other packages in the 0x monorepo and
application developers are not expected to import this package directly.

You may also be interested in the
[@0xproject/contract-wrappers](../contract-wrappers/README.md) package which
includes some higher-level features.

## Installation

```bash
yarn add @0xproject/abi-gen-wrappers
```

**Import**

```typescript
import * as wrappers from '@0xproject/abi-gen-wrappers';
```

or

```javascript
var wrappers = require('@0xproject/abi-gen-wrappers');
```

## 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/abi-gen-wrappers yarn build
```

### Clean

```bash
yarn clean
```

### Lint

```bash
yarn lint
```

### Run Tests

```bash
yarn test
```
41 changes: 41 additions & 0 deletions packages/abi-gen-wrappers/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"name": "@0xproject/abi-gen-wrappers",
"version": "1.0.0",
"engines": {
"node": ">=6.12"
},
"description": "Low-level 0x smart contract wrappers generated using @0xproject/abi-gen",
"main": "lib/src/index.js",
"directories": {
"test": "test"
},
"scripts": {
"build": "yarn pre_build && tsc -b",
"build:ci": "yarn build",
"pre_build": "yarn generate_contract_wrappers",
"clean": "shx rm -rf lib wrappers",
"generate_contract_wrappers": "abi-gen --abis ${npm_package_config_abis} --template ../contract_templates/contract.handlebars --partials '../contract_templates/partials/**/*.handlebars' --output src/generated-wrappers --backend ethers"
},
"config": {
"abis": "../contract-artifacts/artifacts/@(AssetProxyOwner|DummyERC20Token|DummyERC721Token|ERC20Proxy|ERC20Token|ERC721Proxy|ERC721Token|Exchange|Forwarder|IValidator|IWallet|OrderValidator|WETH9|ZRXToken).json"
},
"repository": {
"type": "git",
"url": "https://github.com/0xProject/0x-monorepo.git"
},
"license": "Apache-2.0",
"bugs": {
"url": "https://github.com/0xProject/0x-monorepo/issues"
},
"homepage": "https://github.com/0xProject/0x-monorepo/packages/abi-gen-wrappers/README.md",
"devDependencies": {
"@0xproject/abi-gen": "^1.0.12",
"shx": "^0.2.2"
},
"dependencies": {
"@0xproject/base-contract": "^3.0.1"
},
"publishConfig": {
"access": "public"
}
}
Loading

0 comments on commit dbf5be6

Please sign in to comment.