Skip to content
This repository has been archived by the owner on Jan 11, 2022. It is now read-only.

HAECHI-LABS/audit-Cojam

Repository files navigation

Cojam Contract Repository

Requirement

  • node.js
  • node-gyp

Dev Environment Setting

clone code
$ git clone git@github.com:haechi-labs/audit-cojam
install packages
$ cd audit-cojam
$ npm install

Deployment

Method 1. Using mnemonic

fill in mnemonic to truffle-config.js:3

...
const mnemonic = 'YOURMNEMONIC';
...

write infura key for connecting to ethereum nodes in truffle-config.js:5

...
const privateKey = 'YOURINFURAKEY';
...

DEPLOY!!

$ npx truffle migrate --network mainnet

you'll see deployed contract address in the console

Method 2. Using privateKey

install privatekey provider package from npm

$ npm install truffle-privatekey-provider

change HDWalletProvider to privatekey provider in truffle-config.js:1

const HDWalletProvider = require('truffle-privatekey-provider');

change HDWalletProvider to get privateKey instead of mnemonic in line 11,18,26 of truffle-config.js

- return new HDWalletProvider(mnemonic, `https://mainnet.infura.io/v3/${infurakey}`);
+ return new HDWalletProvider(privateKey, `https://mainnet.infura.io/v3/${infurakey}`);

fill in privateKey to truffle-config.js:4

...
const privateKey = 'YOURPRIVATEKEY';
...

write infura key for connecting to ethereum nodes in truffle-config.js:5

...
const privateKey = 'YOURINFURAKEY';
...

DEPLOY!!

$ npx truffle migrate --network mainnet

you'll see deployed contract address in the console

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published