You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
2
+
3
+
http://www.apache.org/licenses/LICENSE-2.0
4
+
5
+
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copy file name to clipboardexpand all lines: README.md
+28-73
Original file line number
Diff line number
Diff line change
@@ -2,14 +2,15 @@
2
2
3
3
---
4
4
5
-
Originally authored by Zondax. Learn more at [zondax.ch](https://www.zondax.ch).
6
-
Protocol Labs are now the owners of this library, and will mantain it moving forward.
5
+
[Protocol Labs](https://protocol.ai/) are now the owners of this library, and will mantain it moving forward.
6
+
7
+
Originally authored by [Zondax](https://www.zondax.ch).
7
8
8
9
---
9
10
10
11
## Notice
11
12
12
-
This is software is available under Apache 2.0 License. Use of this library implies your acceptance of these terms and conditions
13
+
This software is dual-licensed under the [MIT License](./LICENSE-MIT) and the [Apache Software License v2](./LICENSE-APACHE) by way of the [Permissive License Stack](https://protocol.ai/blog/announcing-the-permissive-license-stack/). Use of this library implies your acceptance of these terms and conditions.
13
14
14
15
Things to keep in mind, while using this library:
15
16
@@ -73,29 +74,36 @@ import { MarketTypes } from "./libs/types/MarketTypes.sol";
73
74
74
75
#### NPM Package
75
76
76
-
A better approach to import these libs is using the NPM package created for this. [:link:](https://www.npmjs.com/package/@zondax/filecoin-solidity).
77
-
Run on your project in order to add this package.
77
+
Better approach to import these libs is using the [NPM package](https://www.npmjs.com/package/filecoin-solidity) created for this .
78
78
79
-
```yarn
80
-
yarn add @zondax/filecoin-solidity
79
+
```
80
+
$ npm install filecoin-solidity
81
81
```
82
82
83
-
In your smart contract, copy and paste these lines.
83
+
#### Foundry (git)
84
84
85
-
```solidity
86
-
import { MarketAPI } from "@zondax/filecoin-solidity/contracts/v0.8/MarketAPI.sol";
87
-
import { CommonTypes } from "@zondax/filecoin-solidity/contracts/v0.8/types/CommonTypes.sol";
88
-
import { MarketTypes } from "@zondax/filecoin-solidity/contracts/v0.8/types/MarketTypes.sol";
89
-
import { BigInt } from "@zondax/filecoin-solidity/contracts/v0.8/cbor/BigIntCbor.sol";
85
+
> [!WARNING]
86
+
> When installing via git, it is a common error to use the `master` branch. This is a development branch that should be avoided in favor of tagged releases. The release process involves security measures that the `master` branch does not guarantee.
87
+
88
+
> [!WARNING]
89
+
> Foundry installs the latest version initially, but subsequent `forge update` commands will use the `master` branch.
90
+
91
+
```
92
+
$ forge install filecoin-solidity
90
93
```
91
94
92
-
### Supported networks
95
+
Add `filecoin-solidity/=lib/filecoin-solidity/` in `remappings.txt.`
93
96
94
-
The following table contains information about the versions of filecoin network on which the `filecoin-solidity` library has been tested on.
In your smart contract, copy and paste these lines.
100
+
101
+
```solidity
102
+
import { MarketAPI } from "filecoin-solidity/contracts/v0.8/MarketAPI.sol";
103
+
import { CommonTypes } from "filecoin-solidity/contracts/v0.8/types/CommonTypes.sol";
104
+
import { MarketTypes } from "filecoin-solidity/contracts/v0.8/types/MarketTypes.sol";
105
+
import { BigInt } from "filecoin-solidity/contracts/v0.8/cbor/BigIntCbor.sol";
106
+
```
99
107
100
108
## Complementary lectures
101
109
@@ -119,59 +127,6 @@ Find nice articles with rich and valuable content about different topics related
119
127
120
128
Filecoin solidity documentation: [Let's go to docs web](https://docs.filecoin.io/smart-contracts/developing-contracts/solidity-libraries/):arrow_upper_right:
0 commit comments