Quick deploy (re-originate)
Factori lets you quickly re-originate a contract you have imported from the blockchain.
The syntax is
factori deploy OPTIONS CONTRACT_NAME
where
CONTRACT_NAME
is the name under which you have imported your contract. If you don't remember it, you can look up the filecontracts.json
in you Factori project folder, it will appear in thecontract_name
field as in:json "contracts": [ { "contract_name": "test", "original_format": "kT1", "original_kt1": [ "KT1Ty5iiGhgBKxUgAbNbSPU58dx6J3ULVRdk", "mainnet" ], "import_date": "13/4/2023 11:50:6", "options": [ "ocaml", "csharp" ]
where the name of the contract is test.OPTIONS
can benetwork
is the network you wish to deploy to. Typical choices will beghostnet
(wherealice
fromflextesa
is an account which is always replenished and from which you can originate for free) orflextesa
if you are deploying in a sandbox).--ocaml
means that an OCaml interface will be used to deploy the contract. For this to work, you will need to have generated the OCaml SDK for your contract;--typescript
means that a Typescript interface will be used to deploy the contract. For this to work, you will need to have generated the Typescript SDK for your contract.--storage
is the initial storage you want to use, it can be eitherrandom
orblockchain
:random
will use a randomly generated storageblockchain
will use the initial blockchain storage from the contract at the time you imported it. Please note that this will not, however, include the content ofbig_map
s. Other languages will be added in thedeploy
command in the future.
When run, this command will generate a (OCaml or Typescript) scenario which deploys your contract to the desired network. Upon successful deployment, the scenario will be destroyed. If the deployment fails, the scenario will remain so that you can debug what went wrong or submit an issue.