mirror of https://github.com/nicolargo/glances.git
Correct issue with 2 digit instead of one in Glances UI MEM
This commit is contained in:
parent
7edbab35d8
commit
6361217258
|
|
@ -110,7 +110,7 @@ export default {
|
||||||
return this.data.views['mem'];
|
return this.data.views['mem'];
|
||||||
},
|
},
|
||||||
percent() {
|
percent() {
|
||||||
return this.stats['percent'].toFixed(2);
|
return this.stats['percent'].toFixed(1);
|
||||||
},
|
},
|
||||||
total() {
|
total() {
|
||||||
return this.stats['total'];
|
return this.stats['total'];
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -136,7 +136,7 @@ class QuicklookPlugin(GlancesPluginModel):
|
||||||
mem_available + zfs_cache_stats.get('arcstats.size', 0) - zfs_cache_stats.get('arcstats.c_min', 0)
|
mem_available + zfs_cache_stats.get('arcstats.size', 0) - zfs_cache_stats.get('arcstats.c_min', 0)
|
||||||
)
|
)
|
||||||
|
|
||||||
stats['mem'] = float((mem_total - mem_available) / mem_total * 100)
|
stats['mem'] = round(float((mem_total - mem_available) / mem_total * 100), 1)
|
||||||
try:
|
try:
|
||||||
stats['swap'] = psutil.swap_memory().percent
|
stats['swap'] = psutil.swap_memory().percent
|
||||||
except RuntimeError:
|
except RuntimeError:
|
||||||
|
|
@ -320,3 +320,4 @@ class QuicklookPlugin(GlancesPluginModel):
|
||||||
def _mhz_to_hz(self, hz):
|
def _mhz_to_hz(self, hz):
|
||||||
"""Convert Mhz to Hz."""
|
"""Convert Mhz to Hz."""
|
||||||
return hz * 1000000.0
|
return hz * 1000000.0
|
||||||
|
return hz * 1000000.0
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
name: glances
|
name: glances
|
||||||
version: '4.4.0+build01' # Put the current stable version+buildXX (00 for beta/develop)
|
version: '4.4.0+build02' # Put the current stable version+buildXX (00 for beta/develop)
|
||||||
|
|
||||||
summary: Glances an Eye on your system. A top/htop alternative.
|
summary: Glances an Eye on your system. A top/htop alternative.
|
||||||
description: |
|
description: |
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue