Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v2.8.10 #765

Merged
merged 23 commits into from Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
5868740
Packaging: update debian stuff
CarterLi Mar 15, 2024
55ae3a7
CPU (FreeBSD): don't display 0.00 GHz
CarterLi Mar 15, 2024
6c6d933
Logo: fix colors of arco linux
CarterLi Mar 15, 2024
553124a
Presets: a new example
CarterLi Mar 16, 2024
f902e3b
CPU (Android): don't detect manufactor of Qualcomm as ARM
CarterLi Mar 17, 2024
7c5eb02
Terminal (Linux): ignore `chezmoi`
CarterLi Mar 18, 2024
66bef2f
Network: trim trailing white spaces
CarterLi Mar 19, 2024
f73c3b8
Doc: update changelog
CarterLi Mar 19, 2024
85da30c
Networking: report detailed error messages; support `--thread false` …
CarterLi Mar 20, 2024
75927a8
Networking: add timeout support for TCP connecting
CarterLi Mar 20, 2024
44107f2
Network (Windows): fix compiling
CarterLi Mar 20, 2024
79ae650
Networking: avoid short recv
CarterLi Mar 21, 2024
5e7baa9
PublicIP: error out if non-http protocol is specified
CarterLi Mar 21, 2024
6184b5e
Doc: update changelog
CarterLi Mar 21, 2024
588201f
Windows: update version.rc
CarterLi Mar 21, 2024
a6528cd
Chore: simpify gitignore [ci skip]
CarterLi Mar 22, 2024
50da7ca
GPU (Apple): always use metal to detect vmem
CarterLi Mar 23, 2024
5c97c01
Font (Linux): try fixing style detection
CarterLi Mar 24, 2024
beb564f
CI: try fixing Windows build
CarterLi Mar 25, 2024
3081355
Release: v2.8.10
CarterLi Mar 25, 2024
1f8be43
Disk (Windows): use MS-DOS device name as mountFrom result, instead o…
CarterLi Mar 25, 2024
9681e17
Terminal (Windows): don't use wininit as terminal
CarterLi Mar 25, 2024
0a8056d
TerminalShell (Windows): adjustments
CarterLi Mar 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Expand Up @@ -377,7 +377,7 @@ jobs:
with:
msystem: CLANG64
update: true
install: git mingw-w64-clang-x86_64-7zip mingw-w64-clang-x86_64-cmake mingw-w64-clang-x86_64-clang mingw-w64-clang-x86_64-vulkan-loader mingw-w64-clang-x86_64-opencl-icd
install: git mingw-w64-clang-x86_64-7zip mingw-w64-clang-x86_64-cmake mingw-w64-clang-x86_64-clang mingw-w64-clang-x86_64-vulkan-loader mingw-w64-clang-x86_64-vulkan-headers mingw-w64-clang-x86_64-opencl-icd

- name: print msys version
run: uname -a
Expand Down Expand Up @@ -439,7 +439,7 @@ jobs:
with:
msystem: CLANG32
update: true
install: git mingw-w64-clang-i686-7zip mingw-w64-clang-i686-cmake mingw-w64-clang-i686-clang mingw-w64-clang-i686-vulkan-loader mingw-w64-clang-i686-opencl-icd
install: git mingw-w64-clang-i686-7zip mingw-w64-clang-i686-cmake mingw-w64-clang-i686-clang mingw-w64-clang-i686-vulkan-loader mingw-w64-clang-i686-vulkan-headers mingw-w64-clang-i686-opencl-icd

- name: print msys version
run: uname -a
Expand Down
12 changes: 6 additions & 6 deletions .gitignore
@@ -1,9 +1,9 @@
**/build/
**/.vscode/
**/.cache/
**/.kdev4/
**/.DS_Store
/.vs
build/
.vs/
.vscode/
.cache/
.kdev4/
.DS_Store
cscope.*
tags
fastfetch.kdev4
Expand Down
23 changes: 23 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,26 @@
# 2.8.10

Changes:
* Use MS-DOS device name as mountFrom result, instead of useless GUID volume name (Windows, Disk)
* Some adjustments to Terminal detection (Terminal, Windows)
* Don't pretty print CMD
* Print conhost as Windows Console
* Don't detect `wininit` as Terminal

Bugfixes:
* Don't display 0.00 GHz (CPU, FreeBSD)
* Don't detect manufactor of Qualcomm as ARM (CPU, Android)
* Ignore `chezmoi` (Terminal, Linux)
* Trim trailing possible whitespaces (PublicIP)
* Fix detection compatibility for KDE 6 (Font, Linux)
* Always use Metal API to detect vmem size (GPU, macOS)

Features:
* Improve stability; print more useful error message; avoid misuse (PublicIP / Weather)

Logo:
* Fix color of Arco Linux

# 2.8.9

Bugfixes:
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.12.0) # target_link_libraries with OBJECT libs & project homepage url

project(fastfetch
VERSION 2.8.9
VERSION 2.8.10
LANGUAGES C
DESCRIPTION "Fast neofetch-like system information tool"
HOMEPAGE_URL "https://github.com/fastfetch-cli/fastfetch"
Expand Down
6 changes: 6 additions & 0 deletions debian/changelog
@@ -1,3 +1,9 @@
fastfetch (2.8.9) jammy; urgency=medium

* Update to 2.8.9

-- Carter Li <zhangsongcui@live.cn> Fri, 15 Mar 2024 10:49:42 +0800

fastfetch (2.8.8) jammy; urgency=medium

* Update to 2.8.8
Expand Down
2 changes: 1 addition & 1 deletion debian/files
@@ -1 +1 @@
fastfetch_2.8.8_source.buildinfo universe/utils optional
fastfetch_2.8.9_source.buildinfo universe/utils optional
104 changes: 104 additions & 0 deletions presets/examples/12.jsonc
@@ -0,0 +1,104 @@
{
"$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
"logo": {
"type": "none"
},
"display": {
"separator": "-> "
},
"modules": [
{
"type": "title",
"format": " {6}{7}{8}"
},
"break",
{
"type": "custom",
"format": "┌───────────────────────────── \u001b[1mSystem Information\u001b[0m ─────────────────────────────┐" // `\u001b` is `\033`, or `\e`
},
"break",
{
"key": "  OS ",
"keyColor": "red",
"type": "os"
},
{
"key": "  Machine ",
"keyColor": "green",
"type": "host"
},
{
"key": "  Kernel ",
"keyColor": "magenta",
"type": "kernel"
},
{
"key": " 󰅐 Uptime ",
"keyColor": "red",
"type": "uptime"
},
{
"key": " 󰍹 Resolution ",
"keyColor": "yellow",
"type": "display",
"compactType": "original-with-refresh-rate"
},
{
"key": "  WM ",
"keyColor": "blue",
"type": "wm"
},
{
"key": "  DE ",
"keyColor": "green",
"type": "de"
},
{
"key": "  Shell ",
"keyColor": "cyan",
"type": "shell"
},
{
"key": "  Terminal ",
"keyColor": "red",
"type": "terminal"
},
{
"key": "  CPU ",
"keyColor": "yellow",
"type": "cpu"
},
{
"key": " ﬙ GPU ",
"keyColor": "blue",
"type": "gpu"
},
{
"key": " 󰑭 Memory ",
"keyColor": "magenta",
"type": "memory"
},
{
"key": " 󰩟 Local IP ",
"keyColor": "red",
"type": "localip",
"compact": true
},
{
"key": " 󰩠 Public IP ",
"keyColor": "cyan",
"type": "publicip"
},
"break",
{
"type": "custom",
"format": "└──────────────────────────────────────────────────────────────────────────────┘" // `\u001b` is `\033`, or `\e`
},
"break",
{
"type": "colors",
"paddingLeft": 34,
"symbol": "circle"
}
]
}
65 changes: 20 additions & 45 deletions src/common/font.c
Expand Up @@ -2,6 +2,7 @@
#include "common/font.h"

#include <string.h>
#include <ctype.h>

void ffFontInit(FFfont* font)
{
Expand Down Expand Up @@ -66,59 +67,33 @@ void ffFontInitQt(FFfont* font, const char* data)
//See https://doc.qt.io/qt-5/qfont.html#toString

//Family
while(*data != ',' && *data != '\0')
{
ffStrbufAppendC(&font->name, *data);
++data;
}
if(*data != '\0')
++data;
data = ffStrbufAppendSUntilC(&font->name, data, ',');
ffStrbufTrim(&font->name, ' ');
if (!data) goto exit;
data++;

//Size
while(*data != ',' && *data != '\0')
{
ffStrbufAppendC(&font->size, *data);
++data;
}
if(*data != '\0')
++data;
data = ffStrbufAppendSUntilC(&font->size, data, ',');
ffStrbufTrim(&font->size, ' ');

#define FF_FONT_QT_SKIP_VALUE \
while(*data != ',' && *data != '\0') \
++data; \
if(*data != '\0') \
++data;

FF_FONT_QT_SKIP_VALUE //Pixel size
FF_FONT_QT_SKIP_VALUE //Style hint
FF_FONT_QT_SKIP_VALUE //Font weight
FF_FONT_QT_SKIP_VALUE //Font style
FF_FONT_QT_SKIP_VALUE //Underline
FF_FONT_QT_SKIP_VALUE //Strike out
FF_FONT_QT_SKIP_VALUE //Fixed pitch
FF_FONT_QT_SKIP_VALUE //Always 0

#undef FF_FONT_QT_SKIP_VALUE

while(*data != '\0')
if (!data) goto exit;
data++;

//Style
data = strrchr(data, ',');
if (!data) goto exit;
data++;
if (isalpha(*data))
{
while(*data == ' ')
++data;

if(*data == '\0')
break;

FFstrbuf* style = ffListAdd(&font->styles);
ffStrbufInit(style);
while(*data != ' ' && *data != '\0')
do
{
ffStrbufAppendC(style, *data);
++data;
}
FFstrbuf* style = ffListAdd(&font->styles);
ffStrbufInit(style);
data = ffStrbufAppendSUntilC(style, data, ' ');
if (data) data++;
} while (data);
}

exit:
fontInitPretty(font);
}

Expand Down
14 changes: 4 additions & 10 deletions src/common/networking.h
Expand Up @@ -20,15 +20,9 @@ typedef struct FFNetworkingState {
FFThreadType thread;
#endif
#endif
} FFNetworkingState;

bool ffNetworkingSendHttpRequest(FFNetworkingState* state, const char* host, const char* path, const char* headers);
bool ffNetworkingRecvHttpResponse(FFNetworkingState* state, FFstrbuf* buffer, uint32_t timeout);
uint32_t timeout;
} FFNetworkingState;

static inline bool ffNetworkingGetHttp(const char* host, const char* path, uint32_t timeout, const char* headers, FFstrbuf* buffer)
{
FFNetworkingState state;
if(ffNetworkingSendHttpRequest(&state, host, path, headers))
return ffNetworkingRecvHttpResponse(&state, buffer, timeout);
return false;
}
const char* ffNetworkingSendHttpRequest(FFNetworkingState* state, const char* host, const char* path, const char* headers);
const char* ffNetworkingRecvHttpResponse(FFNetworkingState* state, FFstrbuf* buffer);