Skip to content

Commit

Permalink
publish to npm linea-state-verifier and linea-ccip-gateway packages (#…
Browse files Browse the repository at this point in the history
…231)

* feat: publish to npm linea-state-verifier and linea-ccip-gateway

* chore: update pnpm lock
  • Loading branch information
wantedsystem authored Aug 26, 2024
1 parent 1b896c9 commit 3d38c2b
Show file tree
Hide file tree
Showing 8 changed files with 507 additions and 51 deletions.
6 changes: 3 additions & 3 deletions packages/linea-ccip-gateway/contracts/TestL1.sol
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

import {EVMFetcher} from "linea-state-verifier/contracts/EVMFetcher.sol";
import {EVMFetchTarget} from "linea-state-verifier/contracts/EVMFetchTarget.sol";
import {IEVMVerifier} from "linea-state-verifier/contracts/IEVMVerifier.sol";
import {EVMFetcher} from "@consensys/linea-state-verifier/contracts/EVMFetcher.sol";
import {EVMFetchTarget} from "@consensys/linea-state-verifier/contracts/EVMFetchTarget.sol";
import {IEVMVerifier} from "@consensys/linea-state-verifier/contracts/IEVMVerifier.sol";

contract TestL1 is EVMFetchTarget {
using EVMFetcher for EVMFetcher.EVMFetchRequest;
Expand Down
2 changes: 1 addition & 1 deletion packages/linea-ccip-gateway/contracts/deps.sol
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// SPDX-License-Identifier: MIT

import {LineaSparseProofVerifier} from "linea-state-verifier/contracts/LineaSparseProofVerifier.sol";
import {LineaSparseProofVerifier} from "@consensys/linea-state-verifier/contracts/LineaSparseProofVerifier.sol";
4 changes: 2 additions & 2 deletions packages/linea-ccip-gateway/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "linea-ccip-gateway",
"name": "@consensys/linea-ccip-gateway",
"version": "1.0.0",
"main": "dist/index.js",
"author": "Consensys",
Expand Down Expand Up @@ -34,7 +34,7 @@
"express": "^4.19.2",
"hardhat": "^2.21.0",
"hardhat-gas-reporter": "^1.0.8",
"linea-state-verifier": "link:../linea-state-verifier/",
"@consensys/linea-state-verifier": "^1.0.1",
"mocha": "^10.3.0",
"solidity-coverage": "^0.8.1",
"supertest": "^6.3.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/linea-state-verifier/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ For a detailed readme and usage instructions, see the [monorepo readme](https://
## Installation

```
npm i linea-state-verifier
npm i @consensys/linea-state-verifier
```
53 changes: 53 additions & 0 deletions packages/linea-state-verifier/hardhat.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
import "@nomicfoundation/hardhat-toolbox";
import { HardhatUserConfig } from "hardhat/config";
import "solidity-coverage";
import "hardhat-deploy";
import * as dotenv from "dotenv";

dotenv.config();

const deployer =
process.env.DEPLOYER_PRIVATE_KEY ||
"ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80";

const config: HardhatUserConfig = {
solidity: {
compilers: [
{
version: "0.8.25",
settings: {
optimizer: {
enabled: true,
runs: 200,
},
viaIR: true,
},
},
],
},
networks: {
sepolia: {
url: `https://sepolia.infura.io/v3/${process.env.INFURA_API_KEY}`,
chainId: 11155111,
accounts: [deployer],
},
mainnet: {
url: `https://mainnet.infura.io/v3/${process.env.INFURA_API_KEY}`,
chainId: 1,
accounts: [deployer],
},
},
namedAccounts: {
deployer: {
default: 0,
},
},
etherscan: {
apiKey: {
sepolia: process.env.ETHERSCAN_API_KEY ?? "",
mainnet: process.env.ETHERSCAN_API_KEY ?? "",
},
},
};

export default config;
35 changes: 28 additions & 7 deletions packages/linea-state-verifier/package.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,39 @@
{
"name": "linea-state-verifier",
"version": "1.0.0",
"description": "",
"main": "index.js",
"name": "@consensys/linea-state-verifier",
"version": "1.0.1",
"description": "This library is intended to be used specifacilly to resolve any Linea storage state on L1",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
"compile": "hardhat compile",
"clean": "rm -fr artifacts cache node_modules typechain-types"
},
"keywords": [],
"author": "Consensys",
"license": "Apache-2.0",
"dependencies": {
"@nomicfoundation/hardhat-toolbox": "^5.0.0",
"@openzeppelin/contracts": "^4.9.3",
"chai": "^4.2.0",
"dotenv": "^16.0.3",
"ethers": "^6.13.1",
"hardhat": "^2.17.4"
"hardhat": "^2.17.4",
"hardhat-deploy": "^0.11.12",
"solidity-coverage": "^0.8.12"
},
"devDependencies": {
"@nomicfoundation/hardhat-chai-matchers": "^2.0.0",
"@nomicfoundation/hardhat-ethers": "^3.0.0",
"@nomicfoundation/hardhat-ignition": "^0.15.5",
"@nomicfoundation/hardhat-ignition-ethers": "^0.15.0",
"@nomicfoundation/hardhat-network-helpers": "^1.0.0",
"@nomicfoundation/hardhat-verify": "^2.0.0",
"@nomicfoundation/ignition-core": "^0.15.5",
"@typechain/ethers-v6": "^0.5.0",
"@typechain/hardhat": "^9.0.0",
"@types/chai": "^4.2.0",
"@types/mocha": ">=9.1.0",
"hardhat-gas-reporter": "^1.0.8",
"ts-node": "^10.9.2",
"typechain": "^8.3.0",
"typescript": "^5.5.4"
}
}
}
24 changes: 24 additions & 0 deletions packages/linea-state-verifier/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"include": ["test"],
"compilerOptions": {
"module": "esnext",
"lib": ["dom", "esnext"],
"importHelpers": true,
"declaration": true,
"sourceMap": true,
"rootDir": "./test",
"noUnusedParameters": true,
"moduleResolution": "node",
"jsx": "react",
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true,
"noEmit": true,
"resolveJsonModule": true
},
"ts-node": {
"compilerOptions": {
"module": "commonjs"
}
}
}
Loading

0 comments on commit 3d38c2b

Please sign in to comment.