From 95ab791b2004fec5ef5a698b6233cd9e2f1f2cb2 Mon Sep 17 00:00:00 2001 From: xunmi-pc <寻觅> Date: Fri, 23 Feb 2024 16:03:57 +0800 Subject: [PATCH] =?UTF-8?q?[=E6=9B=B4=E6=96=B0]=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E6=96=B0=E6=97=A7=E4=B8=96=E7=95=8C=E5=88=A4=E6=96=AD=E6=A0=87?= =?UTF-8?q?=E5=87=86,=20=E9=87=87=E7=94=A8=E6=96=B0=E6=97=A7=E4=B8=96?= =?UTF-8?q?=E7=95=8C=E5=85=BC=E5=AE=B9=E5=B1=82=E7=9A=84=E5=88=A4=E6=96=AD?= =?UTF-8?q?=E6=96=B9=E6=B3=95=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .测试.zsh.swp | Bin 24576 -> 0 bytes 安装.zsh | 12 +++++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) delete mode 100644 .测试.zsh.swp diff --git a/.测试.zsh.swp b/.测试.zsh.swp deleted file mode 100644 index b8c37af123012a5d6023a548b7af41ed140c3505..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 24576 zcmeI3Yj7Lab;mc2?HI1zq>r>8I%%&!T6}~cNIg8ZWMrg9&REk}Rvf!Y!%-OsT#Bec zfX0FnWd$y2i6kgKC5xm)QW7aqA|#6hB}EiSkd!|-$s}!NI*!w3CiXPV;O+wX(x%gC z8oQbHfA{PHOOTS{M4o9T3+YF2ch7z7x$koh_g4MY&S%&YmDLhHpOBDecx z^EV`^r8(H>7x(Y-(dArCzPpG?ujqpA7Poq%JChi!d|7F@TN3-ZtpQsD_d)~Bk$TtT zk4PIgR9A`Yik$1%AO67$_abLI4_gDa25b%38n88BYrxiktpQsDwg!GfG!SXJPx?F5 z^>>W=hK%oz6nx)jTt8}jHx)d;-?)Cl_#P^F{!!!l5##&21<#F3`^(mVtpQsDwgzks z*c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ckgrkhPB5Wgby~JEDr6F{{)f5ix3(JbaTt0@*P5Hr-78Tn) zu3Q3!LUGcQu&nVDETtK}|Lg6A{ zAoe6x(Em zNMRDjU1I{#i^MpDA0MNL20MnZvBwd4u8f!vcl6#82%>{2X5^thjNQVkhOG1b3m1|| zvEq$&SxlBn#2W|*4dth)m4YIr(SJ5nZOE%k+&B6j7J{6HC$DC{egPw9>@qf1a9rx; zU}&xkClm7yW&&)7c>ht}KBr4r4=H@04?#W%5)=IdJz|{*>9E9zIQ0}(4T<^`u}G*c zw8fa*XlIBRgUr!<+zYB^hUL&n%$)wHAHwa5`P-Zx)2Ti_b5dJ6MuUnHNTMY1F`5#C zVk}P6vAQsTttH-FKT^*^sVGk0G*d&<5pB7;>ljfqqT>09kk(qW@hZ?+>rh{PRahM29jBli-oD6Z<^u|T zr74`EUHQ!m2!utY+vn2BS)S;@b4;3|pC0ewqstWh`F@};7SfmYRnfvz!9d=I=Ly*fH*?S zgy##@$(6oPqr1@`4u`^uyG{-&vdbIv1`aBI#qABql_HDcL&$tZuyNFlK@*O+SHuqM z>Ja;kweEhD3^vK(A z{aUY${Sq~Z8IVd>E+Xz8$&{7g%L!Y|KGq_coFAhasD^|et#I} z{VMPaob7)G20#xGXa6sP=fGAV>;Tts-aiPc!NcHtIP?D_I1hTki(ox?5PSsu0O$Vi zf$xI92j2m2fNl^3DV+JQfiDAL3wRdn0^)A~eu49U9DEsk3G4<{-~piG?4Jg2gKMB3 zh`9bo!6V=ypy54Lpug{LuQk$sb6W$p25b%38u$&?fNd(Cu}#I|Q1PpMY*VpqDi%k4 z^AF$Fvg+8T;uCS(RBW4yVb{|wrWh{&Uroj0uMA*G2^|OqLf$&}N*gfMew88IDg7Vm C_%bg5 diff --git a/安装.zsh b/安装.zsh index 592f666..b3e637f 100755 --- a/安装.zsh +++ b/安装.zsh @@ -50,8 +50,14 @@ readonly 系统_发行版_名称=$(echo "${NAME}") *loong*) 主机_架构="龙" # 6之前除了5.19以外的所有内核都是旧世界 - if [[ ${系统_版本} =~ ^[3,4,5].+ && !${系统_版本} =~ ^5.19.0-.+ ]]; then - 世界_类型="旧世界" + #if [[ ${系统_版本} =~ ^[3,4,5].+ && !${系统_版本} =~ ^5.19.0-.+ ]]; then + # 世界_类型="旧世界" + #fi + # 使用更高级的方法判断新旧世界 + # 龙架构二进制 第四行是43开头是新世界, 03开头是旧世界 + 世界_类型_标志位=$(hexdump -s 48 -C /usr/bin/sh | head -n 1 | awk '{print $2}') + if [[ ${世界_类型_标志位} == "43" ]];then + 世界_类型="新世界" fi ;; *) @@ -99,7 +105,7 @@ readonly 系统_发行版_名称=$(echo "${NAME}") # 将本机信息更新到指定文件 mkdir -vp ${目录_配置} rm -v ${目录_配置}/信息.zsh - echo "系统_发行版标识=${系统_发行版_标识}" >> ${目录_配置}/信息.zsh + echo "系统_发行版标识=${系统_发行版_标识符}" >> ${目录_配置}/信息.zsh echo "系统_世界类型=${世界_类型}" >> ${目录_配置}/信息.zsh echo "系统_主机架构=${主机_架构}" >> ${目录_配置}/信息.zsh 输出 0 "主机信息检测完毕"