Previous << Update a Contract
Next >> Account Staking Info
この機能はエミュレータでのみ利用可能です。テストネットまたはメインネットではスマートコントラクトを削除することはできません。
Flow CLI を使用して、Flow アカウントにデプロイ済みのスマートコントラクトを削除します。
flow accounts remove-contract <name>
Example Usage
> flow accounts remove-contract FungibleToken
Contract 'FungibleToken' removed from account '0xf8d6e0586b0a20c7'
Address 0xf8d6e0586b0a20c7
Balance 99999999999.70000000
Keys 1
Key 0 Public Key 640a5a359bf3536d15192f18d872d57c98a96cb871b92b70cecb0739c2d5c37b4be12548d3526933c2cda9b0b9c69412f45ffb6b85b6840d8569d969fe84e5b7
Weight 1000
Signature Algorithm ECDSA_P256
Hash Algorithm SHA3_256
Revoked false
Sequence Number 6
Index 0
Contracts Deployed: 0
Testnet Example
> flow accounts remove-contract FungibleToken --signer alice --network testnet
Contract 'FungibleToken' removed from account '0xf8d6e0586b0a20c7'
Address 0xf8d6e0586b0a20c7
Balance 99999999999.70000000
Keys 1
Key 0 Public Key 640a5a359bf3536d15192f18d872d57c98a96cb871b92b70cecb0739c2d5c37b4be12548d3526933c2cda9b0b9c69412f45ffb6b85b6840d8569d969fe84e5b7
Weight 1000
Signature Algorithm ECDSA_P256
Hash Algorithm SHA3_256
Revoked false
Sequence Number 6
Index 0
Contracts Deployed: 0
Arguments
Name
- Name:
name
- Valid inputs: any string value.
コントラクトのソースコードで定義されているスマートコントラクトの名前。
Flags
Signer
- Flag:
--signer
- Valid inputs: the name of an account defined in the configuration (
flow.json
)
トランザクションの署名に使用するアカウント名を指定します。
Include Fields
- Flag:
--include
- Valid inputs:
contracts
結果の出力に含めるフィールドを指定します。テキスト出力のみに適用されます。
Host
- Flag:
--host
- Valid inputs: an IP address or hostname.
- Default:
127.0.0.1:3569
(Flow Emulator)
コマンドを実行する際に使用する Access API のホスト名を指定します。このフラグは、--network
フラグで定義されたホストをすべて上書きします。
Network Key
- Flag:
--network-key
- Valid inputs: ホストのネットワーク公開鍵の 16 進数文字列
コマンドを実行する際に、セキュアなGRPCクライアントを作成するために使用するAccess APIのネットワーク公開鍵を指定します。
Network
- Flag:
--network
- Short Flag:
-n
- Valid inputs: the name of a network defined in the configuration (
flow.json
) - Default:
emulator
どのネットワークに対してコマンドを実行するのかを指定します。
Filter
- Flag:
--filter
- Short Flag:
-x
- Valid inputs: a case-sensitive name of the result property.
結果から、唯一の値として取得したいプロパティの名前を指定します。
Output
- Flag:
--output
- Short Flag:
-o
- Valid inputs:
json
,inline
コマンド結果のフォーマットを指定します。
Save
- Flag:
--save
- Short Flag:
-s
- Valid inputs: a path in the current filesystem.
結果を保存したいファイル名を指定します。
Log
- Flag:
--log
- Short Flag:
-l
- Valid inputs:
none
,error
,debug
- Default:
info
ログレベルを指定します。コマンド実行中に表示する出力を制御します。
Configuration
- Flag:
--config-path
- Short Flag:
-f
- Valid inputs: a path in the current filesystem.
- Default:
flow.json
flow.json
コンフィギュレーションファイルへのパスを指定します。-f
フラグを複数回使用して複数のコンフィグレーションファイルをマージすることもできます。
Version Check
- Flag:
--skip-version-check
- Default:
false
低速なネットワーク接続における処理を高速化するために、起動時のバージョンチェックをスキップします。
Last updated on Dec 17, 2024 by j pimmel
翻訳元
Flow BlockchainのCadence version1.0ドキュメント (Remove a Contract)