mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-29 16:26:39 +01:00
Clean up includes
This commit is contained in:
@@ -1,10 +1,7 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <unistd.h>
|
||||
#include <dirent.h>
|
||||
|
||||
#include <inttypes.h>
|
||||
|
||||
#define FF_BATTERY_MODULE_NAME "Battery"
|
||||
#define FF_BATTERY_NUM_FORMAT_ARGS 5
|
||||
|
||||
|
||||
+1
-2
@@ -1,7 +1,6 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define FF_CPU_MODULE_NAME "CPU"
|
||||
#define FF_CPU_NUM_FORMAT_ARGS 15
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#define FF_CPU_USAGE_MODULE_NAME "CPU Usage"
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#define FF_CURSOR_MODULE_NAME "Cursor"
|
||||
#define FF_CURSOR_NUM_FORMAT_ARGS 2
|
||||
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#define FF_DE_MODULE_NAME "DE"
|
||||
#define FF_DE_NUM_FORMAT_ARGS 3
|
||||
|
||||
|
||||
+3
-3
@@ -1,7 +1,5 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#define FF_GPU_MODULE_NAME "GPU"
|
||||
#define FF_GPU_NUM_FORMAT_ARGS 6
|
||||
|
||||
@@ -61,8 +59,10 @@ static void printGPUList(FFinstance* instance, const FFlist* list)
|
||||
}
|
||||
|
||||
#ifdef FF_HAVE_LIBPCI
|
||||
#include <pci/pci.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <dlfcn.h>
|
||||
#include <pci/pci.h>
|
||||
|
||||
//see https://github.com/pciutils/pciutils/blob/5bdf63b6b1bc35b59c4b3f47f7ca83ca1868155b/ls-kernel.c#L220
|
||||
static void pciGetDriver(struct pci_dev* dev, FFstrbuf* driver, char*(*ffpci_get_param)(struct pci_access*, char*))
|
||||
|
||||
+5
-1
@@ -1,10 +1,14 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <ctype.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define FF_HOST_MODULE_NAME "Host"
|
||||
#define FF_HOST_NUM_FORMAT_ARGS 15
|
||||
|
||||
#ifdef __ANDROID__
|
||||
#include <ctype.h>
|
||||
#endif
|
||||
|
||||
#ifndef __ANDROID__
|
||||
static bool hostValueSet(FFstrbuf* value)
|
||||
{
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#define FF_LOCALE_MODULE_NAME "Locale"
|
||||
#define FF_LOCALE_NUM_FORMAT_ARGS 1
|
||||
|
||||
|
||||
@@ -3,10 +3,9 @@
|
||||
#define FF_LOCALIP_MODULE_NAME "Local IP"
|
||||
#define FF_LOCALIP_NUM_FORMAT_ARGS 1
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <string.h>
|
||||
#include <ifaddrs.h>
|
||||
#include <netinet/in.h>
|
||||
#include <string.h>
|
||||
#include <arpa/inet.h>
|
||||
|
||||
static void printValue(FFinstance* instance, const char* ifaName, const char* addressBuffer)
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#define FF_MEMORY_MODULE_NAME "Memory"
|
||||
#define FF_MEMORY_NUM_FORMAT_ARGS 3
|
||||
|
||||
|
||||
@@ -4,6 +4,8 @@
|
||||
#define FF_OPENCL_NUM_FORMAT_ARGS 3
|
||||
|
||||
#ifdef FF_HAVE_OPENCL
|
||||
#include <dlfcn.h>
|
||||
|
||||
#define CL_TARGET_OPENCL_VERSION 100
|
||||
#include <CL/cl.h>
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
|
||||
#if defined(FF_HAVE_EGL) || defined(FF_HAVE_GLX) || defined(FF_HAVE_OSMESA)
|
||||
#define FF_HAVE_GL 1
|
||||
#include <dlfcn.h>
|
||||
#include <GL/gl.h>
|
||||
|
||||
#define FF_OPENGL_BUFFER_WIDTH 1
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <dirent.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#define FF_PACKAGES_MODULE_NAME "Packages"
|
||||
#define FF_PACKAGES_NUM_FORMAT_ARGS 11
|
||||
@@ -128,6 +130,7 @@ static uint32_t getNixPackages(char* path)
|
||||
}
|
||||
|
||||
#ifdef FF_HAVE_RPM
|
||||
#include <dlfcn.h>
|
||||
#include <rpm/rpmlib.h>
|
||||
#include <rpm/rpmts.h>
|
||||
#include <rpm/rpmdb.h>
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
|
||||
#define FF_SHELL_MODULE_NAME "Shell"
|
||||
#define FF_SHELL_NUM_FORMAT_ARGS 7
|
||||
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <pthread.h>
|
||||
|
||||
#define FF_TERMINAL_MODULE_NAME "Terminal"
|
||||
#define FF_TERMINAL_NUM_FORMAT_ARGS 3
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
#include "fastfetch.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#define FF_WMTHEME_MODULE_NAME "WM Theme"
|
||||
|
||||
Reference in New Issue
Block a user