rename screen-cpu-mem to tmux-mem-cpu-load
This commit is contained in:
parent
b0ef6972bd
commit
dc5fe29f1d
@ -3,7 +3,7 @@ if(COMMAND cmake_policy)
|
|||||||
cmake_policy(VERSION 2.6)
|
cmake_policy(VERSION 2.6)
|
||||||
endif(COMMAND cmake_policy)
|
endif(COMMAND cmake_policy)
|
||||||
|
|
||||||
project(screen-cpu-mem)
|
project( tmux-mem-cpu-load )
|
||||||
|
|
||||||
if(NOT CMAKE_BUILD_TYPE)
|
if(NOT CMAKE_BUILD_TYPE)
|
||||||
set(CMAKE_BUILD_TYPE Release CACHE STRING
|
set(CMAKE_BUILD_TYPE Release CACHE STRING
|
||||||
@ -11,12 +11,8 @@ if(NOT CMAKE_BUILD_TYPE)
|
|||||||
FORCE)
|
FORCE)
|
||||||
endif(NOT CMAKE_BUILD_TYPE)
|
endif(NOT CMAKE_BUILD_TYPE)
|
||||||
|
|
||||||
add_executable(screen-cpu-usage screen-cpu-usage.cpp)
|
add_executable(tmux-mem-cpu-load tmux-mem-cpu-load.cpp)
|
||||||
install(TARGETS screen-cpu-usage
|
install(TARGETS tmux-mem-cpu-load
|
||||||
RUNTIME
|
RUNTIME
|
||||||
DESTINATION bin
|
DESTINATION bin
|
||||||
)
|
)
|
||||||
|
|
||||||
install(PROGRAMS screen-mem-usage
|
|
||||||
DESTINATION bin
|
|
||||||
)
|
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
total_mem=$(/usr/bin/free -m | /usr/bin/awk '$1 == "Mem:" { print $2 }')
|
|
||||||
|
|
||||||
while(true); do
|
|
||||||
current_mem=$(/usr/bin/free -m | /usr/bin/awk '$1 == "-/+" { print $3 }')
|
|
||||||
echo "${current_mem}MB/${total_mem}MB"
|
|
||||||
sleep 3
|
|
||||||
done
|
|
Loading…
Reference in New Issue
Block a user