CLI에서 체인코드 프로젝트 업그레이드

이 명령을 사용하여 업데이트된 Blockchain App Builder의 새로운 기능을 사용하도록 기존 체인코드 프로젝트를 업그레이드할 수 있습니다. 이 명령은 TypeScript 및 Go 프로젝트 모두에서 작동합니다.

Go 프로젝트의 경우, 체인코드 프로젝트를 업그레이드하기 위해 명령을 실행하기 전에 Go v1.20.10으로 업그레이드하십시오.

사용법:

upgrade [options]
my-mac:Project myname$ ochain upgrade -h 
Usage: upgrade [options]
Upgrade App Builder chaincode project 
Options :
    -h, --help              output command usage information
    -D, --debug             enable debug logging
    -p, --project <path>    (optional) Path to Chaincode project to upgrade. If not specified, it defaults to current directory.
    -cc, --chaincode        (optional) To upgrade chaincode project
Examples :
$> ochain upgrade --project <path of chaincode dir>
체인코드 프로젝트를 업그레이드하려면 해당 프로젝트가 포함된 디렉토리로 이동한 후 다음 명령을 입력합니다.
ochain upgrade

체인코드 프로젝트를 업그레이드하는 동안 문제가 발생할 경우 --debug 옵션을 사용하여 디버그 로그를 생성할 수 있습니다. Microsoft Windows에서 --debug 옵션을 지정할 경우 PowerShell 대신 명령 프롬프트를 사용합니다.

체인코드 프로젝트를 업그레이드한 후 사양 파일을 생성된 소스 코드와 동기화합니다. 자세한 내용은 생성된 소스 코드와 사양 파일 변경 사항 동기화를 참조하십시오.