mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-31 10:02:49 +01:00
@@ -5,6 +5,7 @@
|
||||
#include "common/settings.h"
|
||||
#include "detection/gtk.h"
|
||||
#include "detection/displayserver/displayserver.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#include "disk.h"
|
||||
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
#include <limits.h>
|
||||
#include <ctype.h>
|
||||
#include <dirent.h>
|
||||
@@ -19,6 +21,10 @@ static bool isPhysicalDevice(const char* device)
|
||||
if(strcmp(device, "drvfs") == 0)
|
||||
return true;
|
||||
|
||||
//ZFS root pool. The format is rpool/<POOL_NAME>/<VOLUME_NAME>/<SUBVOLUME_NAME>
|
||||
if(strncmp(device, "rpool/", 6) == 0)
|
||||
return true;
|
||||
|
||||
//Pseudo filesystems don't have a device in /dev
|
||||
const char* devPrefix = "/dev/";
|
||||
if(strncmp(device, devPrefix, strlen(devPrefix)) != 0)
|
||||
@@ -141,6 +147,7 @@ static bool isSubvolume(const FFlist* devices)
|
||||
{
|
||||
const FFstrbuf* currentDevie = ffListGet(devices, devices->length - 1);
|
||||
|
||||
//Filter all disks which device was already found. This catches BTRFS subvolumes.
|
||||
for(uint32_t i = 0; i < devices->length - 1; i++)
|
||||
{
|
||||
const FFstrbuf* otherDevice = ffListGet(devices, i);
|
||||
@@ -149,6 +156,11 @@ static bool isSubvolume(const FFlist* devices)
|
||||
return true;
|
||||
}
|
||||
|
||||
//ZFS subvolumes: rpool/<POOL_NAME>/<VOLUME_NAME>/<SUBVOLUME_NAME>.
|
||||
//Test if the third slash is present.
|
||||
if(strncmp(currentDevie->chars, "rpool/", 6) == 0 && ffStrHasNChars(currentDevie->chars, '/', 3))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include "common/properties.h"
|
||||
#include "common/parsing.h"
|
||||
#include "common/processing.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#ifdef FF_HAVE_X11
|
||||
#include "common/library.h"
|
||||
#include "common/parsing.h"
|
||||
#include "util/stringUtils.h"
|
||||
#include <X11/Xlib.h>
|
||||
|
||||
typedef struct X11PropertyData
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "common/properties.h"
|
||||
#include "common/parsing.h"
|
||||
#include "detection/temps/temps_linux.h"
|
||||
#include "util/stringUtils.h"
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <pci/pci.h>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "os.h"
|
||||
#include "common/properties.h"
|
||||
#include "common/parsing.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include "common/parsing.h"
|
||||
#include "detection/terminalshell/terminalshell.h"
|
||||
#include "detection/displayserver/displayserver.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
static const char* getSystemMonospaceFont(const FFinstance* instance)
|
||||
{
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#include "fastfetch.h"
|
||||
#include "terminalshell.h"
|
||||
#include "common/io/io.h"
|
||||
#include "common/parsing.h"
|
||||
#include "common/processing.h"
|
||||
#include "common/thread.h"
|
||||
#include "terminalshell.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
#include <ctype.h>
|
||||
#include <string.h>
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include "common/library.h"
|
||||
#include "common/io/io.h"
|
||||
#include "common/parsing.h"
|
||||
#include "util/stringUtils.h"
|
||||
#include <stdlib.h>
|
||||
#include <vulkan/vulkan.h>
|
||||
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
#ifndef FASTFETCH_INCLUDED_detection_wmtheme
|
||||
#define FASTFETCH_INCLUDED_detection_wmtheme
|
||||
|
||||
#include "fastfetch.h"
|
||||
|
||||
bool ffDetectWmTheme(FFinstance* instance, FFstrbuf* themeOrError);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
#include "fastfetch.h"
|
||||
#include "wmtheme.h"
|
||||
#include "common/properties.h"
|
||||
#include "common/parsing.h"
|
||||
#include "common/settings.h"
|
||||
#include "detection/gtk.h"
|
||||
#include "detection/displayserver/displayserver.h"
|
||||
#include "wmtheme.h"
|
||||
#include "util/stringUtils.h"
|
||||
|
||||
static bool detectWMThemeFromConfigFile(FFinstance* instance, const char* configFile, const char* themeRegex, const char* defaultValue, FFstrbuf* themeOrError)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user