chore: minor improvements

This commit is contained in:
XuehaiPan 2021-07-26 15:37:46 +08:00
parent ff3e1e2242
commit 58147adda9
4 changed files with 10 additions and 3 deletions

View file

@ -13,6 +13,10 @@ RUN apt-get update && \
python3-dev python3-pip python3-setuptools python3-wheel locales && \
rm -rf /var/lib/{apt,dpkg,cache,log}
# Setup locale
ENV LC_ALL C.UTF-8
RUN update-locale LC_ALL="C.UTF-8"
# Install nvitop
COPY . /nvitop
WORKDIR /nvitop
@ -20,5 +24,4 @@ RUN pip3 install --compile .
RUN rm -rf /root/.cache
# Entrypoint
ENV LC_ALL C.UTF-8
ENTRYPOINT [ "python3", "nvitop.py" ]

View file

@ -92,7 +92,7 @@ Install from PyPI ([![PyPI](https://img.shields.io/pypi/v/nvitop?label=PyPI)](ht
pip3 install --upgrade nvitop
```
Install the latest version from GitHub (![Commit Count](https://img.shields.io/github/commits-since/XuehaiPan/nvitop/v0.3.5.6)):
Install the latest version from GitHub (![Commit Count](https://img.shields.io/github/commits-since/XuehaiPan/nvitop/v0.3.6)):
```bash
pip3 install --force-reinstall git+https://github.com/XuehaiPan/nvitop.git#egg=nvitop

View file

@ -255,6 +255,10 @@ class TreeViewScreen(Displayable):
self.addstr(self.y, self.x, 'COMMAND'.ljust(self.width))
self.color_at(self.y, self.x, width=self.width, fg='cyan', attr='bold | reverse')
if len(self.snapshots) == 0:
self.addstr(self.y + 1, self.x, 'No running GPU processes found.')
return
self.selected.within_window = False
for y, process in enumerate(self.snapshots, start=self.y + 1):
prefix_length = len(process.prefix)

View file

@ -3,7 +3,7 @@
"""An interactive NVIDIA-GPU process viewer, the one-stop solution for GPU process management."""
__version__ = '0.3.5.6'
__version__ = '0.3.6'
__license__ = 'GPLv3'
__author__ = __maintainer__ = 'Xuehai Pan'
__email__ = 'XuehaiPan@pku.edu.cn'