ElvenTools / elven-nft-minter-sc

Elven Tools NFT Minter Smart Contract - launching NFTs collections on the MultiversX blockchain
https://www.elven.tools
50 stars 32 forks source link

Upgrade SC #50

Closed PABourdais closed 1 year ago

PABourdais commented 1 year ago

Hey @juliancwirko, I am using the minter SC since April and I wanted to upgrade it to the new version.

To do so I have to update is in .elventoolsrc with the version I want to target

{
    "chain": "mainnet",
    "nftMinterSc": {
        **"version": "v1.10.0",**
        "deployNftMinterSC": "erd1qqqqqqqqqqqqqpgq......."
    }
}

And then I have to trigger the init endpoint with elven-tools nft-minter init ?

Is it the only things to do ?

juliancwirko commented 1 year ago

Hey, unfortunately, there is no cli functionality for upgrading the contract on-chain. Still in TODO. You would need to do the SC upgrade using erdpy for now.

The config you pasted here tells the CLI which version of the SC it should deploy (from the repo), but it will be a newly deployed smart contract. Not upgraded. And the deployNftMinterSC is useful when you need to switch between smart contracts.

I'll try to work on the upgrade functionality soon. Here are all TODO kanban boards: https://github.com/orgs/ElvenTools/projects?type=classic