From c35d351ce54ae369fd9c9f88a443b8d9a9772aef Mon Sep 17 00:00:00 2001 From: smeb y <48400087+a3165458@users.noreply.github.com> Date: Wed, 29 May 2024 16:42:43 +0800 Subject: [PATCH] Update 0g.sh --- 0g.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/0g.sh b/0g.sh index f7c8b6e..8519ed3 100644 --- a/0g.sh +++ b/0g.sh @@ -327,6 +327,24 @@ function export_priv_validator_key() { } +function uninstall_storage_node() { + echo "你确定要卸载0g ai 存储节点程序吗?这将会删除所有相关的数据。[Y/N]" + read -r -p "请确认: " response + + case "$response" in + [yY][eE][sS]|[yY]) + echo "开始卸载节点程序..." + rm -rf $HOME/0g-storage-node + echo "节点程序卸载完成。" + ;; + *) + echo "取消卸载操作。" + ;; + esac +} + + + # 主菜单 function main_menu() { while true; do @@ -352,6 +370,7 @@ function main_menu() { echo "12. 创建存储节点" echo "13. 查看存储节点日志" echo "14. 单独启动存储节点代码,适用于需要修改存储路径等功能修改过后使用" + echo "17. 单独启动存储节点代码,适用于需要修改存储路径等功能修改过后使用" echo "=======================卸载evmos测试网节点功能================================" echo "8. 卸载0gchain验证者节点" echo "15. 卸载旧evmos验证者节点" @@ -376,6 +395,7 @@ function main_menu() { 14) start_storage ;; 15) uninstall_old_node ;; 16) export_priv_validator_key ;; + 17) uninstall_storage_node ;; *) echo "无效选项。" ;; esac