master ohmu/fastfetch-openbsd / src / modules / disk / option.h
ohmu  ·  2026-10-15
 1#pragma once
 2
 3#include "common/option.h"
 4#include "common/percent.h"
 5
 6typedef enum FFDiskVolumeType: uint8_t {
 7    FF_DISK_VOLUME_TYPE_NONE = 0,
 8    FF_DISK_VOLUME_TYPE_REGULAR_BIT = 1 << 0,
 9    FF_DISK_VOLUME_TYPE_HIDDEN_BIT = 1 << 1,
10    FF_DISK_VOLUME_TYPE_EXTERNAL_BIT = 1 << 2,
11    FF_DISK_VOLUME_TYPE_SUBVOLUME_BIT = 1 << 3,
12    FF_DISK_VOLUME_TYPE_UNKNOWN_BIT = 1 << 4,
13    FF_DISK_VOLUME_TYPE_READONLY_BIT = 1 << 5,
14} FFDiskVolumeType;
15
16typedef enum FFDiskCalcType: uint8_t {
17    FF_DISK_CALC_TYPE_FREE,
18    FF_DISK_CALC_TYPE_AVAILABLE,
19} FFDiskCalcType;
20
21typedef struct FFDiskOptions {
22    FFModuleArgs moduleArgs;
23
24    FFstrbuf folders;
25    FFstrbuf hideFolders;
26    FFstrbuf hideFS;
27    FFDiskVolumeType showTypes;
28    FFDiskCalcType calcType;
29    FFPercentageModuleConfig percent;
30} FFDiskOptions;
31
32static_assert(sizeof(FFDiskOptions) <= FF_OPTION_MAX_SIZE, "FFDiskOptions size exceeds maximum allowed size");