Skip to content

Commit fbbfc7f

Browse files
Merge pull request #399 from LinusDierheimer/dev
Release 1.9.0
2 parents 70df34c + e0b2db1 commit fbbfc7f

File tree

126 files changed

+3326
-1433
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+3326
-1433
lines changed

.github/workflows/push.yml

Lines changed: 12 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
uses: actions/checkout@v3
1919

2020
- name: install required packages
21-
run: sudo apt-get update && sudo apt-get install -y libpci-dev libvulkan-dev libwayland-dev libxrandr-dev libxcb-randr0-dev libdconf-dev libdbus-1-dev libmagickcore-dev libxfconf-0-dev libsqlite3-dev rpm librpm-dev libzstd-dev libegl-dev libglx-dev libosmesa6-dev ocl-icd-opencl-dev libcjson-dev
21+
run: sudo apt-get update && sudo apt-get install -y libpci-dev libvulkan-dev libwayland-dev libxrandr-dev libxcb-randr0-dev libdconf-dev libdbus-1-dev libmagickcore-dev libxfconf-0-dev libsqlite3-dev rpm librpm-dev libzstd-dev libegl-dev libglx-dev libosmesa6-dev ocl-icd-opencl-dev libcjson-dev libnm-dev
2222

2323
- name: Initialize CodeQL
2424
uses: github/codeql-action/init@v2
@@ -34,6 +34,9 @@ jobs:
3434
- name: perform CodeQL analysis
3535
uses: github/codeql-action/analyze@v2
3636

37+
- name: list features
38+
run: ./fastfetch --list-features
39+
3740
- name: run fastfetch
3841
run: time ./fastfetch --disable-linewrap false --hide-cursor false --show-errors true --load-config presets/all
3942

@@ -80,6 +83,9 @@ jobs:
8083
- name: perform CodeQL analysis
8184
uses: github/codeql-action/analyze@v2
8285

86+
- name: list features
87+
run: ./fastfetch --list-features
88+
8389
- name: run fastfetch
8490
run: time ./fastfetch --disable-linewrap false --hide-cursor false --show-errors true --load-config presets/all
8591

@@ -113,6 +119,7 @@ jobs:
113119
run: |
114120
cmake -DSET_TWEAK=Off -DBUILD_TESTS=On .
115121
cmake --build . --target package
122+
./fastfetch --list-features
116123
time ./fastfetch --disable-linewrap false --hide-cursor false --show-errors true --load-config presets/all
117124
time ./flashfetch
118125
ctest
@@ -179,6 +186,9 @@ jobs:
179186
- name: copy necessary dlls
180187
run: cp /clang64/bin/{libcjson,libOpenCL,vulkan-1}.dll .
181188

189+
- name: list features
190+
run: ./fastfetch --list-features
191+
182192
- name: run fastfetch
183193
run: time ./fastfetch --disable-linewrap false --hide-cursor false --show-errors true --load-config presets/all
184194

@@ -197,80 +207,6 @@ jobs:
197207
name: fastfetch-windows
198208
path: ./fastfetch-*-Windows.zip
199209

200-
win7:
201-
name: Win7
202-
runs-on: windows-latest
203-
permissions:
204-
security-events: write
205-
contents: read
206-
defaults:
207-
run:
208-
shell: msys2 {0}
209-
steps:
210-
- name: checkout repository
211-
uses: actions/checkout@v3
212-
213-
- name: setup-msys2
214-
uses: msys2/setup-msys2@v2
215-
with:
216-
msystem: MINGW64
217-
update: true
218-
install: git zip mingw-w64-x86_64-cmake mingw-w64-x86_64-gcc mingw-w64-x86_64-cjson mingw-w64-x86_64-vulkan-loader mingw-w64-x86_64-opencl-icd
219-
220-
- name: print msys version
221-
run: uname -a
222-
223-
# https://github.com/msys2/MINGW-packages/issues/13524#event-7555720785
224-
- name: create OpenCL.pc
225-
run: |
226-
cat > /mingw64/lib/pkgconfig/OpenCL.pc << EOF
227-
prefix=/mingw64
228-
exec_prefix=${prefix}
229-
libdir=${exec_prefix}/lib
230-
includedir=${prefix}/include
231-
232-
Name: OpenCL
233-
Description: Open Computing Language generic Installable Client Driver Loader
234-
Version: 2022.09.30-1
235-
Libs: -L${libdir} -lOpenCL.dll
236-
Cflags: -I${includedir}
237-
EOF
238-
239-
- name: Initialize CodeQL
240-
uses: github/codeql-action/init@v2
241-
with:
242-
languages: c, cpp
243-
244-
- name: configure project
245-
run: env PKG_CONFIG_PATH=/mingw64/lib/pkgconfig/:$PKG_CONFIG_PATH cmake -DSET_TWEAK=Off -DBUILD_TESTS=On -DENABLE_BUFFER=Off .
246-
247-
- name: build project
248-
run: cmake --build .
249-
250-
- name: perform CodeQL analysis
251-
uses: github/codeql-action/analyze@v2
252-
253-
- name: copy necessary dlls
254-
run: cp /mingw64/bin/{libcjson,libOpenCL,vulkan-1}.dll .
255-
256-
- name: run fastfetch
257-
run: time ./fastfetch --disable-linewrap false --hide-cursor false --show-errors true --load-config presets/all
258-
259-
- name: run flashfetch
260-
run: time ./flashfetch
261-
262-
- name: run tests
263-
run: ctest
264-
265-
- name: create zip archive
266-
run: zip fastfetch-$(./fastfetch --version-raw)-Win7.zip *.dll fastfetch.exe flashfetch.exe
267-
268-
- name: upload artifacts
269-
uses: actions/upload-artifact@v3
270-
with:
271-
name: fastfetch-win7
272-
path: ./fastfetch-*-Win7.zip
273-
274210
release:
275211
if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository == 'LinusDierheimer/fastfetch'
276212
name: Release
@@ -280,7 +216,6 @@ jobs:
280216
- macos
281217
- freebsd
282218
- windows
283-
- win7
284219
permissions:
285220
contents: write
286221
steps:
@@ -300,4 +235,4 @@ jobs:
300235
tag: ${{ needs.linux.outputs.ffversion }}
301236
commit: ${{ github.sha }}
302237
artifactErrorsFailBuild: true
303-
artifacts: fastfetch-linux/*,fastfetch-macos/*,fastfetch-freebsd/*,fastfetch-windows/*,fastfetch-win7/*
238+
artifacts: fastfetch-linux/*,fastfetch-macos/*,fastfetch-freebsd/*,fastfetch-windows/*

CHANGELOG.md

Lines changed: 47 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,49 @@
1+
# 1.9.0
2+
3+
Notable Changes:
4+
* fastfetch no longer creates a sample config file silently. Use `--gen-config` to generate one.
5+
* fastfetch now search for user config file in the order of `fastfetch --list-config-paths`
6+
* Unknown disks are hidden by default.
7+
* `Resolution` module is renamed to `Display`. (#393)
8+
9+
Features:
10+
* `--logo-padding-top` option (@CarterLi, #372)
11+
* Raw image file as logo support (@CarterLi)
12+
* Look for config files in `$APPDATA` ([RoamingAppData](https://superuser.com/questions/21458/why-are-there-directories-called-local-locallow-and-roaming-under-users-user#answer-21462)) (Windows)
13+
* Look for config files in `~/Library/Preferences` (macOS)
14+
* Add `--list-config-paths` option which list search paths of config files
15+
* Add `--list-data-paths` option which list search paths for presets and logos
16+
* Add `Brightness` module support
17+
* Add `Battery` module support for FreeBSD
18+
* Add `--disk-show-unknown` option for Disk module
19+
* Add `--disk-show-subvolumes` option for Disk module
20+
* Add `--gpu-hide-integrated` option (#379)
21+
* Add `--gpu-hide-discrete` option (#379)
22+
* Detect terminal version when available
23+
* Support `WezTerm` terminal font detection (requires [`wezterm` executable](https://wezfurlong.org/wezterm/cli/general.html) being available)
24+
* Add `--shell-version` and `--terminal-version` options to disable shell / terminal version detection
25+
* Enhance `--percent-type` to allow hiding other texts (#387)
26+
* Add Wifi module support for Linux
27+
* Detect scaled resolutions (Windows, macOS)
28+
* Optimise font module printing (Windows)
29+
* Detect pacman package count inside MSYS2 environment (Windows)
30+
* Add Wifi / Battery module support for Android
31+
* Disk name support for Linux
32+
33+
Logos:
34+
* Raspbian (@IamNoRobot, #373)
35+
36+
Bugfixes:
37+
* `--logo-type` now does accept `iterm` too (@CarterLi, #374)
38+
* Fix mintty terminal font detection (Windows)
39+
* Fix bug that line buffering doesn't work properly (Windows)
40+
* Fix rpm package count detection (Linux)
41+
* Fix cpu temp detection (Linux)
42+
43+
Other:
44+
* Fixed a Typo in iterm error message (@jessebot, #376)
45+
* Don't try to load config file in `/etc` (Windows)
46+
147
# 1.8.2
248

349
Bugfixes:
@@ -112,7 +158,7 @@ Bugfixes:
112158
* Don't segfault in GPU code on Intel Macs (@CarterLi, #236)
113159
* Don't use hardcoded size units in presets (@dr460nf1r3, #255)
114160
* Don't crash with some format strings (#252)
115-
* --logo-none keeps key color now (#264)
161+
* --logo none keeps key color now (#264)
116162

117163
# 1.7.2
118164

CMakeLists.txt

Lines changed: 30 additions & 9 deletions
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 1.8.2
4+
VERSION 1.9.0
55
LANGUAGES C
66
DESCRIPTION "Fast system information tool"
77
HOMEPAGE_URL "https://github.com/LinusDierheimer/fastfetch"
@@ -68,6 +68,7 @@ cmake_dependent_option(ENABLE_GLX "Enable glx" ON "LINUX OR BSD" OFF)
6868
cmake_dependent_option(ENABLE_OSMESA "Enable osmesa" ON "LINUX OR BSD" OFF)
6969
cmake_dependent_option(ENABLE_OPENCL "Enable opencl" ON "LINUX OR BSD OR WIN32" OFF)
7070
cmake_dependent_option(ENABLE_LIBCJSON "Enable libcjson" ON "LINUX OR WIN32" OFF)
71+
cmake_dependent_option(ENABLE_LIBNM "Enable libnm" ON "LINUX" OFF)
7172
cmake_dependent_option(ENABLE_FREETYPE "Enable freetype" ON "ANDROID" OFF)
7273
cmake_dependent_option(ENABLE_THREADS "Enable multithreading" ON "Threads_FOUND AND NOT ANDROID" OFF)
7374
cmake_dependent_option(ENABLE_BUFFER "Enable stdout buffer" ON "LINUX OR APPLE OR BSD OR WIN32 OR ANDROID" OFF)
@@ -102,6 +103,7 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wconversion")
102103
if(WIN32)
103104
set(CMAKE_CXX_STANDARD 11)
104105
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wconversion -fno-exceptions -fno-rtti")
106+
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--tsaware -Wl,--build-id -Wl,--subsystem,console:6.1,--major-os-version,6,--minor-os-version,1")
105107
endif()
106108

107109
# Used for dlopen finding dylibs installed by homebrew
@@ -244,7 +246,6 @@ set(LIBFASTFETCH_SRC
244246
src/detection/packages/packages.c
245247
src/detection/terminalfont/terminalfont.c
246248
src/detection/terminalshell/terminalshell.c
247-
src/detection/title.c
248249
src/detection/vulkan.c
249250
src/logo/builtin.c
250251
src/logo/image/im6.c
@@ -254,13 +255,15 @@ set(LIBFASTFETCH_SRC
254255
src/modules/battery.c
255256
src/modules/bios.c
256257
src/modules/board.c
258+
src/modules/brightness.c
257259
src/modules/break.c
258260
src/modules/chassis.c
259261
src/modules/colors.c
260262
src/modules/cpu.c
261263
src/modules/cpuUsage.c
262264
src/modules/cursor.c
263265
src/modules/custom.c
266+
src/modules/command.c
264267
src/modules/date.c
265268
src/modules/datetime.c
266269
src/modules/de.c
@@ -281,7 +284,7 @@ set(LIBFASTFETCH_SRC
281284
src/modules/poweradapter.c
282285
src/modules/processes.c
283286
src/modules/publicip.c
284-
src/modules/resolution.c
287+
src/modules/display.c
285288
src/modules/separator.c
286289
src/modules/shell.c
287290
src/modules/media.c
@@ -300,6 +303,7 @@ set(LIBFASTFETCH_SRC
300303
src/util/FFlist.c
301304
src/util/FFstrbuf.c
302305
src/util/FFvaluestore.c
306+
src/util/platform/FFPlatform.c
303307
)
304308

305309
if(LINUX)
@@ -309,6 +313,7 @@ if(LINUX)
309313
src/detection/battery/battery_linux.c
310314
src/detection/bios/bios_linux.c
311315
src/detection/board/board_linux.c
316+
src/detection/brightness/brightness_linux.c
312317
src/detection/chassis/chassis_linux.c
313318
src/detection/cpu/cpu_linux.c
314319
src/detection/cpuUsage/cpuUsage_linux.c
@@ -340,14 +345,16 @@ if(LINUX)
340345
src/detection/users/users_linux.c
341346
src/detection/wifi/wifi_linux.c
342347
src/detection/wmtheme/wmtheme_linux.c
348+
src/util/platform/FFPlatform_unix.c
343349
)
344350
elseif(ANDROID)
345351
list(APPEND LIBFASTFETCH_SRC
346352
src/common/networking_linux.c
347353
src/common/processing_linux.c
348-
src/detection/battery/battery_nosupport.c
354+
src/detection/battery/battery_android.c
349355
src/detection/bios/bios_nosupport.c
350356
src/detection/board/board_nosupport.c
357+
src/detection/brightness/brightness_nosupport.c
351358
src/detection/chassis/chassis_nosupport.c
352359
src/detection/cpu/cpu_linux.c
353360
src/detection/cursor/cursor_nosupport.c
@@ -371,17 +378,19 @@ elseif(ANDROID)
371378
src/detection/terminalshell/terminalshell_linux.c
372379
src/detection/uptime/uptime_linux.c
373380
src/detection/users/users_linux.c
374-
src/detection/wifi/wifi_nosupport.c
381+
src/detection/wifi/wifi_android.c
375382
src/detection/wmtheme/wmtheme_nosupport.c
383+
src/util/platform/FFPlatform_unix.c
376384
)
377385
elseif(BSD)
378386
list(APPEND LIBFASTFETCH_SRC
379387
src/common/networking_linux.c
380388
src/common/processing_linux.c
381389
src/common/sysctl.c
382-
src/detection/battery/battery_nosupport.c
390+
src/detection/battery/battery_bsd.c
383391
src/detection/bios/bios_bsd.c
384392
src/detection/board/board_nosupport.c
393+
src/detection/brightness/brightness_nosupport.c
385394
src/detection/chassis/chassis_nosupport.c
386395
src/detection/cpu/cpu_bsd.c
387396
src/detection/cpuUsage/cpuUsage_bsd.c
@@ -413,6 +422,7 @@ elseif(BSD)
413422
src/detection/users/users_linux.c
414423
src/detection/wifi/wifi_nosupport.c
415424
src/detection/wmtheme/wmtheme_linux.c
425+
src/util/platform/FFPlatform_unix.c
416426
)
417427
elseif(APPLE)
418428
list(APPEND LIBFASTFETCH_SRC
@@ -422,6 +432,7 @@ elseif(APPLE)
422432
src/detection/battery/battery_apple.c
423433
src/detection/bios/bios_apple.c
424434
src/detection/board/board_nosupport.c
435+
src/detection/brightness/brightness_apple.c
425436
src/detection/chassis/chassis_nosupport.c
426437
src/detection/cpu/cpu_apple.c
427438
src/detection/cpuUsage/cpuUsage_apple.c
@@ -450,6 +461,7 @@ elseif(APPLE)
450461
src/detection/wmtheme/wmtheme_apple.m
451462
src/util/apple/cf_helpers.c
452463
src/util/apple/osascript.m
464+
src/util/platform/FFPlatform_unix.c
453465
)
454466
elseif(WIN32)
455467
list(APPEND LIBFASTFETCH_SRC
@@ -458,6 +470,7 @@ elseif(WIN32)
458470
src/detection/battery/battery_windows.c
459471
src/detection/bios/bios_windows.c
460472
src/detection/board/board_windows.c
473+
src/detection/brightness/brightness_windows.cpp
461474
src/detection/chassis/chassis_nosupport.c
462475
src/detection/cpu/cpu_windows.c
463476
src/detection/cpuUsage/cpuUsage_windows.c
@@ -483,11 +496,10 @@ elseif(WIN32)
483496
src/detection/wifi/wifi_windows.c
484497
src/detection/wmtheme/wmtheme_windows.c
485498
src/util/windows/getline.c
486-
src/util/windows/pwd.c
487499
src/util/windows/registry.c
488500
src/util/windows/unicode.c
489-
src/util/windows/utsname.c
490501
src/util/windows/wmi.cpp
502+
src/util/platform/FFPlatform_windows.c
491503
)
492504
endif()
493505

@@ -626,6 +638,10 @@ ff_lib_enable(LIBCJSON
626638
"libcjson"
627639
"CJson"
628640
)
641+
ff_lib_enable(LIBNM
642+
"libnm"
643+
"libnm"
644+
)
629645
ff_lib_enable(FREETYPE
630646
"freetype2"
631647
"FreeType2"
@@ -638,7 +654,6 @@ if(ENABLE_THREADS)
638654
endif()
639655
endif()
640656

641-
642657
if(ENABLE_BUFFER)
643658
target_compile_definitions(libfastfetch PRIVATE FF_ENABLE_BUFFER)
644659
endif()
@@ -652,6 +667,7 @@ if(APPLE)
652667
PRIVATE "-framework Cocoa"
653668
PRIVATE "-framework CoreWLAN"
654669
PRIVATE "-weak_framework MediaRemote -F /System/Library/PrivateFrameworks"
670+
PRIVATE "-weak_framework DisplayServices -F /System/Library/PrivateFrameworks"
655671
)
656672
elseif(WIN32)
657673
target_compile_definitions(libfastfetch PRIVATE -D_WIN32_WINNT=0x0601)
@@ -712,6 +728,11 @@ target_link_libraries(flashfetch
712728
PRIVATE libfastfetch
713729
)
714730

731+
if(ENABLE_BUFFER) # FF_ENABLE_BUFFER is used in fastfetch.c
732+
target_compile_definitions(fastfetch PRIVATE FF_ENABLE_BUFFER)
733+
target_compile_definitions(flashfetch PRIVATE FF_ENABLE_BUFFER)
734+
endif()
735+
715736
if(WIN32)
716737
set(TARGET_NAME fastfetch)
717738
target_sources(fastfetch

0 commit comments

Comments
 (0)