Truffle

Truffle is a world class development environment, testing framework and asset pipeline for blockchains using the Ethereum Virtual Machine (EVM), aiming to make life as a developer easier.

Check out Truffle for installation detailsarrow-up-right and an overviewarrow-up-right.

Truffle Configuration for Lycanarrow-up-right

Update the configuration file with the changes shown below for Lycan Chain, providing examples for JavaScript.

const HDWalletProvider = require('@truffle/hdwallet-provider');
const fs = require('fs');
const mnemonic = fs.readFileSync(".secret").toString().trim();

module.exports = {
  networks: {
    lycan: {
      provider: () => new HDWalletProvider(mnemonic, "https://rpc.lycanchain.com"),
      network_id: '*',       // Lycan Chain's network id
      gas: 4500000,          // Gas limit
      gasPrice: 10000000000  // 10 Gwei
    },
  },
  compilers: {
    solc: {
      version: "0.8.4",      // Fetch exact version from solc-bin (default: truffle's version)
    }
  },
  // Set default mocha options here, use special reporters etc.
  mocha: {
    // timeout: 100000
  }
};

Make sure you have the HDWalletProvider package installed by running:

Compile your contractarrow-up-right

Deploy your contractarrow-up-right

View your deployed contract on any of the explorersarrow-up-right.

Last updated