diff --git a/lib/libprintcolor.a b/lib/libprintcolor.a index 11f82ad..6e370f8 100644 Binary files a/lib/libprintcolor.a and b/lib/libprintcolor.a differ diff --git a/objs/ExamAll.o b/objs/ExamAll.o index 748a529..93769f2 100644 Binary files a/objs/ExamAll.o and b/objs/ExamAll.o differ diff --git a/objs/FileSize.o b/objs/FileSize.o new file mode 100644 index 0000000..8154ebd Binary files /dev/null and b/objs/FileSize.o differ diff --git a/objs/Version.o b/objs/Version.o index def616c..7f1205c 100644 Binary files a/objs/Version.o and b/objs/Version.o differ diff --git a/objs/bootstrap.o b/objs/bootstrap.o index c9d1188..3965585 100644 Binary files a/objs/bootstrap.o and b/objs/bootstrap.o differ diff --git a/objs/cmd_utils.o b/objs/cmd_utils.o index a32a447..e000acc 100644 Binary files a/objs/cmd_utils.o and b/objs/cmd_utils.o differ diff --git a/objs/install_utils.o b/objs/install_utils.o index 4040e00..bae6ad6 100644 Binary files a/objs/install_utils.o and b/objs/install_utils.o differ diff --git a/objs/shell_utils.o b/objs/shell_utils.o index d44d60c..fab4fb5 100644 Binary files a/objs/shell_utils.o and b/objs/shell_utils.o differ diff --git a/objs/sl.o b/objs/sl.o new file mode 100644 index 0000000..7d9b152 Binary files /dev/null and b/objs/sl.o differ diff --git a/src/LoginShell/ExamAll.c b/src/LoginShell/ExamAll.c index 4271a03..42a766d 100644 --- a/src/LoginShell/ExamAll.c +++ b/src/LoginShell/ExamAll.c @@ -9,10 +9,11 @@ void login_scripts(const char *script){ if (strcmp(script, "exam") == 0){ system("curl -O https://heng1.oss-cn-beijing.aliyuncs.com/systeminfo.sh && cp systeminfo.sh /etc/profile.d/ && chmod +x /etc/profile.d/systeminfo.sh"); - printf("\033[1;34m成功设置登录自动检查系统信息,可自行扩展脚本\033[0m\n"); + color_printf(cyan,"成功设置登录自动检查系统信息,可自行扩展脚本\n"); + system("rm -f systeminfo.sh"); } else { - color_printf(cyan,"CmdUtils的登录自动化执行功能暂不支持该参数\n"); + color_printf(red,"CmdUtils的登录自动化执行功能暂不支持该参数\n"); } } \ No newline at end of file diff --git a/src/Utils/Version.c b/src/Utils/Version.c index 9191bfe..bc96fe0 100644 --- a/src/Utils/Version.c +++ b/src/Utils/Version.c @@ -9,7 +9,7 @@ void print_version(const char *script){ if (strcmp(script, "version") == 0){ - char version[] = "3.0.1"; + char version[] = "3.20"; // 使用printf函数打印版本号 printf("当前版本是: %s\n", version); diff --git a/src/Utils/cmd_utils.c b/src/Utils/cmd_utils.c index 53b6c27..07386ae 100644 --- a/src/Utils/cmd_utils.c +++ b/src/Utils/cmd_utils.c @@ -50,6 +50,6 @@ void show_command_usage(const char *command) { }else if (strcmp(command, "sl") == 0) { // 增加的sl命令 }else { - color_printf(cyan,"CmdUtils的提示功能暂不支持命令\n"); + color_printf(red,"CmdUtils的提示功能暂不支持命令\n"); } } \ No newline at end of file diff --git a/src/Utils/shell_utils.c b/src/Utils/shell_utils.c index e138cae..2bfddff 100644 --- a/src/Utils/shell_utils.c +++ b/src/Utils/shell_utils.c @@ -9,9 +9,10 @@ void shell_scripts(const char *script){ if (strcmp(script, "env") == 0){ system("env"); }else if(strcmp(script, "banner") == 0){ - system("vim /etc/motd"); + system(""); }else if(strcmp(script, "exam") == 0){ - system("cat /etc/os-release"); + system("curl -O https://heng1.oss-cn-beijing.aliyuncs.com/systeminfo.sh && cp systeminfo.sh /etc/profile.d/ && chmod +x /etc/profile.d/systeminfo.sh"); + system("rm -f systeminfo.sh"); }else if(strcmp(script, "cpu") == 0){ system("lscpu"); }else if(strcmp(script, "free") == 0){