Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/detection/packages/packages.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ typedef struct FFPackagesResult {
uint32_t sorcery;
uint32_t winget;
uint32_t xbps;
uint32_t ror;

uint32_t all; // Make sure this goes last

Expand Down
7 changes: 7 additions & 0 deletions src/detection/packages/packages_linux.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "packages.h"
#include "common/io.h"
#include "common/parsing.h"
#include "common/processing.h"
#include "common/properties.h"
#include "common/settings.h"
#include "common/strutil.h"
Expand Down Expand Up @@ -568,6 +569,12 @@ 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, ROR)) {
FF_STRBUF_AUTO_DESTROY output = ffStrbufCreate();
if (ffProcessAppendStdOut(&output, (char* const[]) { "ror", "count", NULL }) == NULL) {
packageCounts->ror += (uint32_t) ffStrbufToUInt(&output, 0);
}
}
}

static void getPackageCountsRegular(FFstrbuf* baseDir, FFPackagesResult* packageCounts, FFPackagesOptions* options) {
Expand Down
2 changes: 1 addition & 1 deletion src/fastfetch.c
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ static void parseCommand(FFdata* data, char* key, char* value) {
enableJsonOutput(data);
}
} else if (ffStrEqualsIgnCase(key, "--dynamic-interval")) {
instance.state.dynamicInterval = ffOptionParseUInt32(key, value); // seconds to milliseconds
instance.state.dynamicInterval = ffOptionParseUInt32(key, value);
} else {
return;
}
Expand Down
16 changes: 16 additions & 0 deletions src/logo/ascii/r.inc
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,22 @@ static const FFlogo R[] = {
},
},
#endif
#ifdef FASTFETCH_DATATEXT_LOGO_RORKOS
// RorkOS
{
.names = { "rorkos", "RorkOS" },
.lines = FASTFETCH_DATATEXT_LOGO_RORKOS,
.colors = {
FF_COLOR_FG_WHITE,
FF_COLOR_FG_WHITE,
FF_COLOR_FG_WHITE,
FF_COLOR_FG_WHITE,
FF_COLOR_FG_WHITE,
},
.colorKeys = FF_COLOR_FG_WHITE,
.colorTitle = FF_COLOR_FG_WHITE,
},
#endif
// LAST
{},
};
24 changes: 24 additions & 0 deletions src/logo/ascii/r/rorkos.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
.ooo. $2.gggggggggggg$1.
ooooo $2.gggggggggggggggg$1.
ooooo $2.ggggg$3rrrrrrrr$2gggggg$1.
ooooo$2.gggg$3rrrrrrrrrrrr$2ggggg
oooo$2gggg$3rrrrr$4@@@@@$3rrrr$2gggg
oooo$2gggg$3rrrr$4@@@@@@@$3rrr$2gggg
oooo$2gggg$3rrrr$4@@@@@@@$3rrr$2gggg
oooo$2gggg$3rrrr$4@@@@@$3rrrrr$2gggg
ooooo$2.ggggg$3rrrrrrrrrrr$2gggg$1`
ooooo $2 gggggg$3rrrrrrr$2ggggg$1`
ooooo$5WW$2 gggggggggggggggg$1`
ooooo$5WWWW $2`aaaaaaaaaa`$1
ooooo$5WWWWW
ooooo$5WWWWWWW
ooooo $5WWWWWWW
ooooo $5WWWWWWW
ooooo $5WWWWWWWW
ooooo $5WWWWWWWW
ooooo $5WWWWWWW
ooooo $5WWWWWWW
ooooo $5WWWWWWW
ooooo $5WWWWWWW$1`
ooooo $5WWWWWWW
`ooo` $5`WWWW`
1 change: 1 addition & 0 deletions src/modules/packages/option.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ typedef enum FF_A_PACKED FFPackagesFlags {
FF_PACKAGES_FLAG_CARDS_BIT = UINT64_C(1) << 34U,
FF_PACKAGES_FLAG_PORG_BIT = UINT64_C(1) << 35U,
FF_PACKAGES_FLAG_INSTALLRELEASE_BIT = UINT64_C(1) << 36U,
FF_PACKAGES_FLAG_ROR_BIT = UINT64_C(1) << 37U,
FF_PACKAGES_FLAG_FORCE_UNSIGNED = UINT64_MAX,
} FFPackagesFlags;
static_assert(sizeof(FFPackagesFlags) == sizeof(uint64_t), "");
Expand Down
6 changes: 6 additions & 0 deletions src/modules/packages/packages.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ bool ffPrintPackages(FFPackagesOptions* options) {
FF_PRINT_PACKAGE(pkgsrc)
FF_PRINT_PACKAGE(pkgtool)
FF_PRINT_PACKAGE(porg)
FF_PRINT_PACKAGE(ror)
FF_PRINT_PACKAGE(rpm)
if (options->combined) {
FF_PRINT_PACKAGE_ALL(scoop);
Expand Down Expand Up @@ -185,6 +186,7 @@ bool ffPrintPackages(FFPackagesOptions* options) {
FF_ARG(counts.pkgsrc, "pkgsrc"),
FF_ARG(counts.pkgtool, "pkgtool"),
FF_ARG(counts.porg, "porg"),
FF_ARG(counts.ror, "ror"),
FF_ARG(counts.rpm, "rpm"),
FF_ARG(counts.scoopGlobal, "scoop-global"),
FF_ARG(counts.scoopUser, "scoop-user"),
Expand Down Expand Up @@ -333,6 +335,7 @@ void ffParsePackagesJsonObject(FFPackagesOptions* options, yyjson_val* module) {
case 'R':
if (false)
;
FF_TEST_PACKAGE_NAME(ROR)
FF_TEST_PACKAGE_NAME(RPM)
break;
case 'S':
Expand Down Expand Up @@ -413,6 +416,7 @@ void ffGeneratePackagesJsonConfig(FFPackagesOptions* options, yyjson_mut_doc* do
FF_TEST_PACKAGE_NAME(PKGSRC)
FF_TEST_PACKAGE_NAME(PKGTOOL)
FF_TEST_PACKAGE_NAME(PORG)
FF_TEST_PACKAGE_NAME(ROR)
FF_TEST_PACKAGE_NAME(RPM)
FF_TEST_PACKAGE_NAME(SCOOP)
FF_TEST_PACKAGE_NAME(SNAP)
Expand Down Expand Up @@ -481,6 +485,7 @@ bool ffGeneratePackagesJsonResult(FFPackagesOptions* options, yyjson_mut_doc* do
FF_APPEND_PACKAGE_COUNT(pkgsrc)
FF_APPEND_PACKAGE_COUNT(pkgtool)
FF_APPEND_PACKAGE_COUNT(porg)
FF_APPEND_PACKAGE_COUNT(ror)
FF_APPEND_PACKAGE_COUNT(rpm)
FF_APPEND_PACKAGE_COUNT(scoopGlobal)
FF_APPEND_PACKAGE_COUNT(scoopUser)
Expand Down Expand Up @@ -558,6 +563,7 @@ FFModuleBaseInfo ffPackagesModuleInfo = {
{ "Number of pkgsrc packages", "pkgsrc" },
{ "Number of pkgtool packages", "pkgtool" },
{ "Number of porg packages", "porg" },
{ "Number of ror packages", "ror" },
{ "Number of rpm packages", "rpm" },
{ "Number of scoop-global packages", "scoop-global" },
{ "Number of scoop-user packages", "scoop-user" },
Expand Down