Added cpu and gpu info
This commit is contained in:
parent
623ff235f0
commit
4f1a36553a
|
@ -12,9 +12,8 @@
|
|||
#+ATTR_HTML: :alt fetchy Screenshot :title fetchy Screenshot :align left
|
||||
[[https://gitlab.com/vojjvoda/fetchy/-/raw/master/screenshot.png]]
|
||||
|
||||
fetchy is a minimal command line system information tool written in C.
|
||||
fetchy - simple cli system information tool written in C.
|
||||
|
||||
It displays the os, kernel, uptime, number of installed packages, shell, CPU and GPU info.
|
||||
|
||||
* Install
|
||||
|
||||
|
|
2
info.h
2
info.h
|
@ -16,7 +16,7 @@ void getCPU(){
|
|||
|
||||
|
||||
void getGPU(){
|
||||
FILE *gpuName = popen("lspci -v | rg VGA -m 1 | awk -F'[' '{ print $2 }' | awk -F']' '{ print $1 }' ", "r");
|
||||
FILE *gpuName = popen("lspci -v | grep VGA -m 1 | awk -F'[' '{ print $2 }' | awk -F']' '{ print $1 }' ", "r");
|
||||
|
||||
fscanf(gpuName, "%[^\n]%s", &gpu);
|
||||
fclose(gpuName);
|
||||
|
|
Loading…
Reference in a new issue