diff --git a/src/detection/os/os_linux.c b/src/detection/os/os_linux.c index 2f270f1b0..97f39d6d9 100644 --- a/src/detection/os/os_linux.c +++ b/src/detection/os/os_linux.c @@ -397,6 +397,14 @@ static void detectOS(FFOSResult* os) { ffStrbufSetS(&os->name, "HarmonyOS"); ffStrbufSetS(&os->prettyName, "HarmonyOS"); } + + // SemiOS if we have /bin/packie + if (ffPathExists("/bin/packie", FF_PATHTYPE_ANY)) { + ffStrbufSetS(&os->id, "semios"); + ffStrbufSetS(&os->idLike, "semios"); + ffStrbufSetS(&os->name, "SemiOS"); + ffStrbufSetS(&os->prettyName, "SemiOS"); + } } } diff --git a/src/detection/packages/packages.h b/src/detection/packages/packages.h index e91dfe2dc..0c49317eb 100644 --- a/src/detection/packages/packages.h +++ b/src/detection/packages/packages.h @@ -52,6 +52,7 @@ typedef struct FFPackagesResult { uint32_t sorcery; uint32_t winget; uint32_t xbps; + uint32_t packie; uint32_t all; // Make sure this goes last diff --git a/src/detection/packages/packages_linux.c b/src/detection/packages/packages_linux.c index 2440ebec6..77766b073 100644 --- a/src/detection/packages/packages_linux.c +++ b/src/detection/packages/packages_linux.c @@ -574,6 +574,10 @@ static void getPackageCounts(FFstrbuf* baseDir, FFPackagesResult* packageCounts, if (FF_PACKAGES_IS_ENABLED(options, CARDS)) { packageCounts->cards += getNumElements(baseDir, "/var/lib/pkg/DB", true); } + if (FF_PACKAGES_IS_ENABLED(options, PACKIE)) { + packageCounts->packie += getNumElements(baseDir, "/pkg", true); + + } } static void getPackageCountsRegular(FFstrbuf* baseDir, FFPackagesResult* packageCounts, FFPackagesOptions* options) { diff --git a/src/logo/ascii/s.inc b/src/logo/ascii/s.inc index 8fc7e0c66..50421ae73 100644 --- a/src/logo/ascii/s.inc +++ b/src/logo/ascii/s.inc @@ -525,6 +525,14 @@ static const FFlogo S[] = { }, }, #endif + #ifdef FASTFETCH_DATATEXT_LOGO_SEMIOS + // SemiOS + { + .names = { "SemiOS" }, + .lines = FASTFETCH_DATATEXT_LOGO_SEMIOS, + .colors = {}, + }, + #endif // LAST {}, }; diff --git a/src/logo/ascii/s/semios.txt b/src/logo/ascii/s/semios.txt new file mode 100644 index 000000000..6ed763899 --- /dev/null +++ b/src/logo/ascii/s/semios.txt @@ -0,0 +1,20 @@ +  +  + :   + l,    ,.  + .: :  ,l ;. ,,  + ,c:  :l  o  l  :,  ,   + ,c: ,l l,.c :. :;,  .,   + .;;: ,c:,,    ..,;. .,,,.   + ,:,.  .;;, .,,.     +  .,::::::: ,:::::.  + ,:::::: ,,,,,,...   +     .;;,   .::.    ...  +  ,;;;: ,c:,,    .,.,. ,::.  +  ;,  ,c: ,l l,.: ;, ,:.  +  ,  :c  d ;  ;:  .,.   + :c  .l :. , ..  + ,; .:  + ,  +  +  diff --git a/src/modules/packages/option.h b/src/modules/packages/option.h index 2cf734b57..eb50ac3b1 100644 --- a/src/modules/packages/option.h +++ b/src/modules/packages/option.h @@ -43,6 +43,7 @@ typedef enum FFPackagesFlags: uint64_t { FF_PACKAGES_FLAG_INSTALLRELEASE_BIT = UINT64_C(1) << 36U, FF_PACKAGES_FLAG_CRUX_BIT = UINT64_C(1) << 37U, FF_PACKAGES_FLAG_RUM_BIT = UINT64_C(1) << 38U, + FF_PACKAGES_FLAG_PACKIE_BIT = UINT64_C(1) << 39U, } FFPackagesFlags; static_assert(sizeof(FFPackagesFlags) == sizeof(uint64_t), "");