안녕하세요 이번에 새롭게 토큰 생성 등에 대해 공부를 하고있는 한 학생입니다.
ide에서 클론 코딩을 통해 만들어서 배포를 한 적이 있는데요, 해당 내용은 휘발성으로 토큰은 생성 되지만 유지하며 메소드를 쓸 수 없는 형식인 것 같았습니다.
그래서 찾던 와중에 truffle을 사용하여 배포하는 것을 찾았고 GitHub - klaytn/klaytn-contracts 의 깃도 확인할 수 있었습니다.
하지만 클론을 받고 환경세팅을 하던 중 질문 사항이 있어서 이렇게 메일 보냅니다…!!
-
해당 내용을 클론 받으면 토큰 명, 토큰 수량 등은 어디서 설정을 해야하나요?
-
clone을 받은 사용자가 수정해야할 내용은 truffle-config.js 파일의 const privateKey = “0x123”, const cypressPrivateKey = “0x456” 이 두가지인 건가요??
-
node 버전 v10.20.0 인데 npm run deploy:klaytn 을 하면 ReferenceError: TextDecoder is not defined 이런 에러를 뿜습니다… 검색을 해보니 node 버전을 올리라고 하는데 마냥 올리기만 해도 될까요? 현 버전이 안정적이라는 이야기를 들어서요…
package.json 의 내용입니다.
{
"name": "klaytn-contract",
"version": "1.0.0",
"description": "various contracts for Klaytn",
"repository": "https://github.com/klaytn/klaytn-contracts.git",
"author": "Klaytn",
"license": "MIT",
"bugs": {
"url": "https://github.com/klaytn/klaytn-contracts/issues"
},
"homepage": "https://github.com/klaytn/klaytn-contracts",
"scripts": {
"build": "truffle compile",
"test": "concurrently --success first --kill-others \"yarn run:ganache\" \"yarn test:ganache\"",
"run:ganache": "ganache-cli -l 80000000 -q -k constantinople",
"run:klaytn": "./test/prepare.sh",
"run:klaytn:start": "./test/prepare.sh",
"run:klaytn:stop": "./test/stop.sh",
"run:klaytn:resume": "./test/resume.sh",
"run:klaytn:terminate": "./test/terminate.sh",
"run:klaytn:log": "find -s ./test -name tee.*.log | tail -1 | xargs -I{} tail -f {}",
"run:klaytn:cleanlog": "find -s ./test -name tee.*.log -delete",
"test:ganache": "truffle test",
"test:klaytn": "truffle test --network klaytn",
"deploy:klaytn": "truffle deploy --network klaytn",
"deploy:baobab": "truffle deploy --network baobab",
"deploy:cypress": "truffle deploy --network cypress"
},
"dependencies": {
"caver-js": "^1.5.0",
"caver-js-ext-kas": "^1.0.1",
"truffle-hdwallet-provider-klaytn": "^1.0.18"
},
"devDependencies": {
"concurrently": "^5.3.0",
"ganache-cli": "^6.12.1",
"truffle": "^5.1.23",
"openzeppelin-test-helpers": "^0.3.2",
"truffle-assertions": "^0.9.2"
}
}
질문이 너무 길지만… 한번 도움을 주시면 감사드릴 것 같습니다…