Skip to content

router-protocol/router-contract-scripts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Router Protocol Contract Deployment Scripts

This repository contains scripts and tools for deploying Router Protocol smart contracts across different blockchain networks. It supports both EVM and zkSync deployments.

Prerequisites

  • Node.js (v16 or higher)
  • Yarn package manager
  • Git
  • Foundry (for contract compilation)

Project Structure

.
├── contracts/               # Smart contract submodules
├── src/                    # Source code for deployment scripts
├── build.sh               # Build script for contract compilation
└── package.json          # Project dependencies and scripts

Setup

  1. Clone the repository and initialize submodules:
git submodule update --remote --merge                                                                                              
  1. Install dependencies:
yarn install
  1. Set up your environment variables:
    • Copy .env.example to .env
    • Add your private keys and other configuration

Usage

Building Contracts

To build the contracts for native EVM:

yarn build

To build for zkSync:

yarn build --zksync

Deploying Contracts

  1. Start the deployment process:
yarn start
  1. Follow the CLI prompts to:
    • Import your private key
    • Select the network
    • Deploy contracts

Available Scripts

  • yarn start: Start the deployment process
  • yarn build: Build contracts for native EVM
  • yarn build --zksync: Build contracts for zkSync

Dependencies

The project uses several key dependencies:

  • @coral-xyz/anchor
  • @ethersproject/abi
  • @openzeppelin/upgrades-core
  • @solana/web3.js
  • ethers
  • and more (see package.json for complete list)

Security

Private keys are stored in the ./config/lrsc folder and are encrypted with a password. This provides an additional layer of security for your sensitive credentials.

License

MIT License

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy