Skip to content

Commit ea162fd

Browse files
authored
Merge pull request #734 from fastfetch-cli/dev
Release: v2.8.4
2 parents 30d3d00 + b80391b commit ea162fd

File tree

29 files changed

+743
-162
lines changed

29 files changed

+743
-162
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,7 @@ Output of `fastfetch --list-features`:
4646
Paste the stacktrace here. You may get it with:
4747

4848
```
49-
$ gdb /path/to/fastfetch
50-
$ run
51-
$ bt
49+
$ gdb -q -ex 'set confirm off' -ex run -ex 'bt full' -ex quit --args /path/to/fastfetch
5250
```
5351

5452
If you are able to identify which module crashed, the strace can be helpful too

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
# 2.8.4
2+
3+
Bugfixes:
4+
* Fix segfault if we fail to find `Vendor ID` in `lscpu` (#718, CPU, Linux)
5+
* Fix multi-device bcachefs filesystem compatibility (#731, Disk, Linux)
6+
7+
Features:
8+
* Support portable Windows Terminal settings (#720, Terminal, Windows)
9+
* Support `--color-block-width` and `--color-block-range` (#721, Colors)
10+
* Support `--diskio-detect-total` to show total bytes read/written (DiskIO)
11+
* Support `--netio-detect-total` to show total bytes received/sent (NetIO)
12+
* Support `--packages-disabled` to disable specified package manager (#729, Packages)
13+
* Support `--display-order` to sort multiple displays in a specific order (Display)
14+
* Support `--display-compact-type original-with-refresh-rate` to show refresh rates in compact (oneline) mode (Display)
15+
116
# 2.8.3
217

318
Bugfixes:

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.12.0) # target_link_libraries with OBJECT libs & project homepage url
22

33
project(fastfetch
4-
VERSION 2.8.3
4+
VERSION 2.8.4
55
LANGUAGES C
66
DESCRIPTION "Fast neofetch-like system information tool"
77
HOMEPAGE_URL "https://github.com/fastfetch-cli/fastfetch"
@@ -1112,6 +1112,9 @@ set(CPACK_GENERATOR "TGZ;ZIP")
11121112
if(APPLE)
11131113
string(TOLOWER "${CMAKE_PROJECT_NAME}-macos-universal" CPACK_PACKAGE_FILE_NAME)
11141114
else() # We don't use this in Windows
1115+
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")
1116+
set(CMAKE_SYSTEM_PROCESSOR "amd64")
1117+
endif()
11151118
string(TOLOWER "${CMAKE_PROJECT_NAME}-${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}" CPACK_PACKAGE_FILE_NAME)
11161119
endif()
11171120

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ There are [screenshots on different platforms](https://github.com/fastfetch-cli/
3232
* Fedora: `sudo dnf install fastfetch`
3333
* Gentoo: `sudo emerge --ask app-misc/fastfetch`
3434
* Alpine: `apk add --upgrade fastfetch`
35-
* NixOS: `sudo nix-shell -p fastfetch`
35+
* NixOS: `nix-shell -p fastfetch`
3636
* openSUSE: `sudo zypper install fastfetch`
3737
* ALT Linux: `sudo apt-get install fastfetch`
3838

doc/json_schema.json

Lines changed: 49 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1007,6 +1007,29 @@
10071007
"type": "integer",
10081008
"minimum": 0,
10091009
"default": 0
1010+
},
1011+
"block": {
1012+
"description": "Set behavior of block printing",
1013+
"type": "object",
1014+
"properties": {
1015+
"width": {
1016+
"description": "Set the block width in spaces",
1017+
"type": "integer",
1018+
"minimum": 1,
1019+
"default": 3
1020+
},
1021+
"range": {
1022+
"description": "Set the range of colors in the blocks to print",
1023+
"type": "array",
1024+
"items": {
1025+
"type": "integer",
1026+
"minimum": 0,
1027+
"maximum": 15
1028+
},
1029+
"minItems": 2,
1030+
"maxItems": 2
1031+
}
1032+
}
10101033
}
10111034
}
10121035
},
@@ -1078,7 +1101,9 @@
10781101
"enum": [
10791102
"none",
10801103
"original",
1081-
"scaled"
1104+
"scaled",
1105+
"original-with-refresh-rate",
1106+
"scaled-with-refresh-rate"
10821107
],
10831108
"description": "Set if all displays should be printed in one line",
10841109
"default": "none"
@@ -1088,6 +1113,15 @@
10881113
"type": "boolean",
10891114
"default": false
10901115
},
1116+
"order": {
1117+
"description": "Set the order should be used when printing",
1118+
"enum": [
1119+
"none",
1120+
"asc",
1121+
"desc"
1122+
],
1123+
"default": "none"
1124+
},
10911125
"key": {
10921126
"$ref": "#/$defs/key"
10931127
},
@@ -1173,6 +1207,11 @@
11731207
"description": "Show disks with given name prefix only",
11741208
"type": "string"
11751209
},
1210+
"detectTotal": {
1211+
"description": "Detect total bytes instead of current rate",
1212+
"type": "boolean",
1213+
"default": false
1214+
},
11761215
"key": {
11771216
"$ref": "#/$defs/key"
11781217
},
@@ -1382,6 +1421,11 @@
13821421
"type": "boolean",
13831422
"default": true
13841423
},
1424+
"detectTotal": {
1425+
"description": "Detect total bytes instead of current rate",
1426+
"type": "boolean",
1427+
"default": false
1428+
},
13851429
"key": {
13861430
"$ref": "#/$defs/key"
13871431
},
@@ -1436,10 +1480,10 @@
14361480
"const": "packages",
14371481
"description": "List installed package managers and count of installed packages"
14381482
},
1439-
"winget": {
1440-
"description": "Set if winget package count should be detected.\nNote this is very slow operation. Please make sure `winget list` works before enable this option\nWindows only",
1441-
"type": "boolean",
1442-
"default": false
1483+
"disabled": {
1484+
"description": "A colon separated list of package managers to be disabled when detecting",
1485+
"type": "string",
1486+
"default": "winget"
14431487
},
14441488
"key": {
14451489
"$ref": "#/$defs/key"

src/data/help.json

Lines changed: 102 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,10 @@
122122
{
123123
"long": "ds-force-drm",
124124
"desc": "Set if only DRM should be used to detect displays",
125-
"remark": "Use this option if you encountered problems with other detection method. Linux only",
125+
"remark": [
126+
"Use this option if you encountered problems with other detection method.",
127+
"Linux only"
128+
],
126129
"arg": {
127130
"type": "enum",
128131
"optional": true,
@@ -537,7 +540,13 @@
537540
{
538541
"long": "percent-type",
539542
"desc": "Set the percentage output type",
540-
"remark": "1 for percentage number, 2 for bar, 3 for both, 6 for bar only, 9 for colored number",
543+
"remark": [
544+
"1 for percentage number",
545+
"2 for bar",
546+
"3 for both",
547+
"6 for bar only",
548+
"9 for colored number"
549+
],
541550
"arg": {
542551
"type": "num",
543552
"default": 9
@@ -963,6 +972,14 @@
963972
"default": false
964973
}
965974
},
975+
{
976+
"long": "diskio-detect-total",
977+
"desc": "Detect total bytes instead of current rate",
978+
"arg": {
979+
"type": "bool",
980+
"default": false
981+
}
982+
},
966983
{
967984
"long": "diskio-name-prefix",
968985
"desc": "Show disks with given name prefix only",
@@ -996,13 +1013,16 @@
9961013
}
9971014
},
9981015
{
999-
"long": "packages-winget",
1000-
"desc": "Set if winget package count should be detected",
1001-
"remark": "This option is extremely slow. You may need to increase value of '--processing-timeout' to make it actually work",
1016+
"long": "packages-disabled",
1017+
"desc": "A colon separated list of package managers to be disabled when detecting",
1018+
"remark": [
1019+
"Some detection methods can be very slow.",
1020+
"You may need to increase value of '--processing-timeout' to make it actually work.",
1021+
"Use `--packages-disabled none` to enable all."
1022+
],
10021023
"arg": {
1003-
"type": "bool",
1004-
"optional": true,
1005-
"default": false
1024+
"type": "string",
1025+
"default": "winget"
10061026
}
10071027
},
10081028
{
@@ -1013,7 +1033,9 @@
10131033
"enum": {
10141034
"none": "Disable this compact mode",
10151035
"original": "Print original resolutions",
1016-
"scaled": "Print scaled resolutions"
1036+
"scaled": "Print scaled resolutions",
1037+
"original-with-refresh-rate": "Print original resolutions with refresh rate",
1038+
"scaled-with-refresh-rate": "Print scaled resolutions with refresh rate"
10171039
},
10181040
"default": "none"
10191041
}
@@ -1027,6 +1049,19 @@
10271049
"default": false
10281050
}
10291051
},
1052+
{
1053+
"long": "display-order",
1054+
"desc": "Set the order should be used when printing displays",
1055+
"arg": {
1056+
"type": "enum",
1057+
"enum": {
1058+
"none": "Use the detected order",
1059+
"asc": "Sort by display name ascendingly",
1060+
"desc": "Sort by display name descendingly"
1061+
},
1062+
"default": "none"
1063+
}
1064+
},
10301065
{
10311066
"long": "brightness-ddcci-sleep",
10321067
"desc": "Set the sleep times (in ms) when sending DDC/CI requests",
@@ -1052,7 +1087,10 @@
10521087
{
10531088
"long": "battery-use-setup-api",
10541089
"desc": "Set if \"SetupAPI\" should be used on Windows to detect battery info",
1055-
"remark": "SetupAPI supports multi batteries, but slower. Windows only",
1090+
"remark": [
1091+
"SetupAPI supports multi batteries, but slower.",
1092+
"Windows only"
1093+
],
10561094
"arg": {
10571095
"type": "bool",
10581096
"optional": true,
@@ -1088,7 +1126,10 @@
10881126
{
10891127
"long": "de-slow-version-detection",
10901128
"desc": "Set if DE version should be detected with slow operations",
1091-
"remark": "Usually is not necessary. Linux only",
1129+
"remark": [
1130+
"It's only used as a fallback method. Please file a bug report if you encounter any issues.",
1131+
"Linux only"
1132+
],
10921133
"arg": {
10931134
"type": "bool",
10941135
"optional": true,
@@ -1107,7 +1148,10 @@
11071148
{
11081149
"long": "gpu-driver-specific",
11091150
"desc": "Use driver specific method to detect more detailed GPU information (memory usage, core count, etc)",
1110-
"remark": "Correctly NVML (NVIDIA) and IGCL (Intel, Windows only) are supported. Both require the latest proprietary driver to be installed",
1151+
"remark": [
1152+
"Correctly NVML (NVIDIA) and IGCL (Intel, Windows only) are supported.",
1153+
"Both require the latest proprietary driver to be installed."
1154+
],
11111155
"arg": {
11121156
"type": "bool",
11131157
"optional": true,
@@ -1225,6 +1269,14 @@
12251269
"default": true
12261270
}
12271271
},
1272+
{
1273+
"long": "netio-detect-total",
1274+
"desc": "Detect total bytes instead of current rate",
1275+
"arg": {
1276+
"type": "bool",
1277+
"default": false
1278+
}
1279+
},
12281280
{
12291281
"long": "publicip-timeout",
12301282
"desc": "Time in milliseconds to wait for the public ip server to respond",
@@ -1342,6 +1394,44 @@
13421394
"type": "num",
13431395
"default": 0
13441396
}
1397+
},
1398+
{
1399+
"long": "colors-block-width",
1400+
"desc": "Set the block width in spaces",
1401+
"arg": {
1402+
"type": "num",
1403+
"default": 3
1404+
}
1405+
},
1406+
{
1407+
"long": "colors-block-range-start",
1408+
"desc": "Set the start range of colors in the blocks to print",
1409+
"remark": [
1410+
"Display colors 0-15 in the blocks. (16 colors)",
1411+
"Display colors 0-7 in the blocks. (8 colors)",
1412+
"Only works for `--colors-symbol block`.",
1413+
"Must be in range 0-15",
1414+
"See also `--colors-range-end`"
1415+
],
1416+
"arg": {
1417+
"type": "num",
1418+
"default": 0
1419+
}
1420+
},
1421+
{
1422+
"long": "colors-block-range-end",
1423+
"desc": "Set the end range of colors in the blocks to print",
1424+
"remark": [
1425+
"Display colors 0-15 in the blocks. (16 colors)",
1426+
"Display colors 0-7 in the blocks. (8 colors)",
1427+
"Only works for `--colors-symbol block`.",
1428+
"Must be in range 0-15",
1429+
"See also `--colors-range-start`"
1430+
],
1431+
"arg": {
1432+
"type": "num",
1433+
"default": 15
1434+
}
13451435
}
13461436
],
13471437
"General module": [

src/detection/cpu/cpu_linux.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,10 @@ const char* ffDetectCPUImpl(const FFCPUOptions* options, FFCPUResult* cpu)
266266
return NULL;
267267
}
268268
}
269+
else
270+
{
271+
pstart = buffer.chars;
272+
}
269273
}
270274

271275
while ((pstart = strstr(pstart, "Model name:")))

src/detection/disk/disk.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
const char* ffDetectDisksImpl(FFlist* disks);
44

5-
static int compareDisks(const void* disk1, const void* disk2)
5+
static int compareDisks(const FFDisk* disk1, const FFDisk* disk2)
66
{
7-
return ffStrbufCompAlphabetically(&((const FFDisk*) disk1)->mountpoint, &((const FFDisk*) disk2)->mountpoint);
7+
return ffStrbufComp(&disk1->mountpoint, &disk2->mountpoint);
88
}
99

1010
const char* ffDetectDisks(FFDiskOptions* options, FFlist* disks)
@@ -18,7 +18,7 @@ const char* ffDetectDisks(FFDiskOptions* options, FFlist* disks)
1818
// For example for /boot/efi/bootmgr we need to check /boot/efi before /boot
1919
//Note that we sort alphabetically here for a better ordering when printing the list,
2020
// so the check must be done in reverse order
21-
ffListSort(disks, compareDisks);
21+
ffListSort(disks, (void*) compareDisks);
2222
FF_LIST_FOR_EACH(FFDisk, disk, *disks)
2323
{
2424
if(disk->bytesTotal == 0)

src/detection/disk/disk_linux.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,10 @@ static bool isPhysicalDevice(const struct mntent* device)
4141
if(!ffStrStartsWith(device->mnt_fsname, "/dev/"))
4242
return false;
4343

44+
//#731
45+
if(ffStrEquals(device->mnt_type, "bcachefs"))
46+
return true;
47+
4448
if(
4549
ffStrStartsWith(device->mnt_fsname + 5, "loop") || //Ignore loop devices
4650
ffStrStartsWith(device->mnt_fsname + 5, "ram") || //Ignore ram devices

0 commit comments

Comments
 (0)