Commit Graph

149 Commits

Author SHA1 Message Date
Clement Tsang bde2dac56e
deps: bump various dependencies as of 2023-03-27 (#1079) 2023-03-28 01:14:10 -04:00
Clement Tsang 444d2f7ad7
deps: bump sysinfo to 0.28 (#1078)
* deps: update sysinfo to 0.28.0

* 0.28.1

* 0.28.2

* 0.28.3

* 0.28.4
2023-03-27 00:50:21 -04:00
Clement Tsang 9fc62b9fd6
deps: forgot to bump crossterm back to 0.26.1 (#1069) 2023-03-15 20:47:10 -04:00
Clement Tsang 8fe3f1f23c
deps: revert crossterm 0.26.1 to fix double input bug on Windows (#1066) 2023-03-14 17:52:52 -04:00
Clement Tsang b745684156
refactor: more data collection cleanup (#1047)
* refactor: more memory collection cleanup

* more cleanup

* clean up data_harvester, remove heim sensor flag

Separate out most individual components to separate functions. Also
remove Linux's usage of heim's sensors feature, since I wasn't using it
apparently.

* clean up GPU section

* fix cond

* fix feature flags

* more cleanup

* even more cleanup
2023-03-07 00:18:24 -05:00
Clement Tsang 994c11e3b3
refactor: migrate network collection to sysinfo (#1041)
* refactor: migrate network collection to sysinfo

* remove net feature from heim

* comments and changelog
2023-03-04 01:34:52 -05:00
Clement Tsang 8cc763cc1b
refactor: migrate memory collection to sysinfo for all platforms (#1036)
* cleanup

* refactor: remove heim memory code

* add missing updates, remove heim memory feature

* restrict export visibility

* some refactoring, remove smol

* gpu feature
2023-03-03 00:06:19 -05:00
Clement Tsang c2d94900f3
deps: bump procfs to 0.15.1 (#1038) 2023-03-02 17:40:56 -05:00
Clement Tsang f26d598410
refactor: migrate CPU from heim to sysinfo for all platforms (#1035)
* refactor: migrate CPU from heim to sysinfo for all platforms

* fix windows and macos imports

* simplify a bit of code

* cleanup
2023-03-02 00:03:54 -05:00
Clement Tsang e8ae1a265a
other: switch to toml_edit (#1034) 2023-03-01 00:14:47 -05:00
Clement Tsang f02bd21948
deps: bump crossterm to 0.26.1 (#1033) 2023-02-28 00:10:08 -05:00
Clement Tsang 44e52d6229
deps: bump nvml to 0.9.0 (#1032) 2023-02-27 19:37:35 -05:00
Clement Tsang 6fa72290a9
deps: bump patch dependency versions as of 2023-02-26 (#1031) 2023-02-27 01:44:15 -05:00
Clement Tsang 6d15f01009
other: support hw.temperature-based temps on FreeBSD (#1024)
* other: support hw.temperature-based temps for FreeBSD

* update changelog

* enable sysctl always for freebsd
2023-02-19 18:44:35 -05:00
spital 021a727f19
other: replace deprecated `value_of` and `is_present` in clap
* Upgrade clap to 3.2.2 to allow future fix warnings

* cargo fmt fix

* Replaced deprecated `value_of` and `is_present`, builds with no warnings, clap 3.2.2

* cargo fmt

* updated according to comments. builds fine, cargo test fine

* Match some versions

* Update Cargo.lock

* Fix typo, mb

---------

Co-authored-by: Clement Tsang <34804052+ClementTsang@users.noreply.github.com>
2023-01-31 19:34:52 -05:00
Clement Tsang f416c54d2f
other: bump to 0.8.1 for nightly (#1002) 2023-01-24 20:54:26 -05:00
ClementTsang 490e94c347
other: bump to 0.8.0 2023-01-20 18:55:31 -05:00
Clement Tsang 639c93b4c8
other: switch to windows-rs for process killing (#985) 2023-01-18 01:43:08 -05:00
Clement Tsang 316891d476
deps: update more dependencies as of 2022-01-14 (#982) 2023-01-14 22:36:30 -05:00
Clement Tsang 8490ff93ea
deps: update regex to 1.7.1 (#981) 2023-01-14 21:19:10 -05:00
Clement Tsang 80ef86e12a
deps: updates unicode deps to support unicode 15 (#980) 2023-01-14 21:05:58 -05:00
Clement Tsang f712aaffa1
deps: updates some minor deps as of 2023-01-14 (#979)
Updates:
- log
- serde
- itertools
2023-01-14 19:13:31 -05:00
Clement Tsang 9292dbd376
deps: update indexmap to 1.9.2 (#978) 2023-01-14 19:03:49 -05:00
Clement Tsang 719c35ae3b
deps: update procfs to 0.14.2 (#977) 2023-01-14 18:37:29 -05:00
ClementTsang f415fb08bc
other: bump up version in Cargo.toml to 0.7.2 2023-01-12 05:20:22 -05:00
Clement Tsang a56e7f6cc9
feature: split usage into usage percentage and value (#950)
Denotes both usage and usage percentage. This also redoes the calculation for percentage to be based on the sum of avail + used, rather than on total, as otherwise we get potentially confusing percentages.
2023-01-01 05:08:04 -05:00
Clement Tsang 46884d48f0
uptick: 0.7.0 (#940) 2022-12-31 17:50:20 -05:00
Clement Tsang db07246f67
other: don't use manual map for color name mapping (#908)
* other: don't use manual map for color name mapping

I actually don't know why I was doing it like that before.

This commit removes the phf crate, as it's not needed anymore.

* update test
2022-11-21 03:34:33 -05:00
Clement Tsang 63df220a38
other: clean up some strings (#904)
* other: clean up some strings

* formatting
2022-11-20 02:21:20 -05:00
Clement Tsang 6a0bf10760
other: some cleanup in proc widget (#903) 2022-11-20 01:13:24 -05:00
Clement Tsang a07fa305fb
bug: redirect stderr on FreeBSD to avoid drawing on UI (#897) 2022-11-17 03:18:05 -05:00
Clement Tsang b2c301b1fe
deps: update sysctl to 0.5.2, procfs to 0.14.1 (#894) 2022-11-13 17:43:55 -05:00
Clement Tsang 17ca30c023
other: remove flume (#893)
In hindsight, pulling in flume is probably overkill and doesn't really
help much.
2022-11-13 01:59:45 -05:00
Clement Tsang 50768907ec
feature: add custom retention periods for data (#892)
* feature: add custom retention periods for data

* docs: update changelog

* docs: update docs
2022-11-13 01:51:10 -05:00
Clement Tsang f5ec9191f2
other: try using flume for channel (#884) 2022-11-10 01:08:06 -05:00
Clement Tsang 8101e6fa56
deps: Update tui to 0.19.0 and crossterm to 0.25.0 (#878)
* deps: update tui to 0.19 and crossterm to 0.25

* fix error

* handle breaking changes
2022-11-08 00:56:39 -05:00
Clement Tsang e6e1e9d688
deps: update nvml to 0.8.0 (#869) 2022-11-05 02:12:31 -04:00
Clement Tsang ec21306f55
deps: update sysinfo to 0.26.7 (#867) 2022-11-04 19:38:14 -04:00
Clement Tsang 2a740f48f7
refactor: tables V2 (#749)
* refactor: move to new data table implementation

* more work towards refactor

* move disk and temp over, fix longstanding bug with disk and temp if removing the last value and selected

* work towards porting over CPU

work towards porting over CPU

fix typo

partially port over cpu, fix some potentially inefficient concat_string calls

more work towards cpu widget migration

some refactoring

* sortable data

sortable data

more refactoring

some sort refactoring

more refactoringgggg

column refactoring

renaming and reorganizing

more refactoring regarding column logic

add sort arrows again

* move over sort menu

* port over process

port over process

precommit

temp

temp two, remember to squash

work

fix broken ltr calculation and CPU hiding

add back row styling

temp

fix a bunch of issues, get proc working

more fixes around click

fix frozen issues

* fix dd process killing

* revert some of the persistent config changes from #257

* fix colouring for trees

* fix missing entries in tree

* keep columns if there is no data

* add and remove tests

* Fix ellipsis
2022-10-12 16:25:38 -04:00
Clement Tsang 1e5f0ea2d9
bug: add bindings to grab ppid in some cases on macos (#825) 2022-10-11 19:49:39 -04:00
Clement Tsang a965e53c6c
fix wrong unit being used for memory in sysinfo data (#824)
* fix wrong unit being used for memory in sysinfo data

* update sysinfo to 0.26.4 for unsupported reasons w/ ntapi
2022-10-07 19:15:11 -04:00
ClementTsang dfd21f57dc
other: bump to 0.6.9 for nightly to avoid confusion for now 2022-09-25 17:25:44 -04:00
Clement Tsang c6c7fb3a30
deps: update sysinfo to 0.26.2 (#806)
* deps: update sysinfo to 0.26.2

This dependency update has some nice things in store for us:
- MacOS M1 temperature support
- Bevy of bug fixes

* update documentation

* some fixes
2022-09-16 04:42:24 -04:00
Clement Tsang a427a9d2f2
other: add zfs to deploy feature set (#808) 2022-09-14 05:50:34 -04:00
Justin Martin 6e0bc96093
feature: Add zfs feature flag for arc memory (#784)
* freebsd clippy

* add arc support

* Code Review: moved runtime cfg checks to compile time and formatting

* remove compile platform checks

* add zfs feature flag to get_arc_data
2022-08-22 02:47:22 -04:00
Wesley Moore 577fda96fc
Implement support for FreeBSD (#766)
* WIP FreeBSD support

* Implement get_cpu_data_list for FreeBSD

* Implement disks for FreeBSD

It doesn't work though as sysinfo doesn't make the device name available.

* Use libxo to read process cpu info on FreeBSD

* Populate get_io_usage with libxo too

Actual I/O stats still aren't populated though as there's not an
easy source for them.

* Share more processes code between macos and freebsd

* Extract function for deserializing libxo output on FreeBSD

* Implement filtering of disks in FreeBSD

* Clean up memory data collection

* Update module docs
2022-07-23 20:44:29 -04:00
Clement Tsang 4ceaf8d008
deps: migrate to starship-battery (#724)
Migrates the `battery` dependency to the more actively maintained
`starship-battery` fork, found at https://github.com/starship/rust-battery.
See https://github.com/svartalf/rust-battery/pull/92 for more information.
2022-05-06 17:16:57 -04:00
ClementTsang 2401e583fb refactor: consolidate time graph components
This consolidates all the time graph drawing to one main location, as well
as some small improvements. This is helpful in that I don't have to
reimplement the same thing across three locations if I have to make one
change that in theory should affect them all. In particular, the CPU
graph, memory graph, and network graph are all now using the same,
generic implementation for drawing, which we call (for now) a component.

Note this only affects drawing - it accepts some parameters affecting style
and labels, as well as data points, and draw similarly to how it used to
before. Widget-specific actions, or things affecting widget state,
should all be handled by the widget-specific code instead. For example,
our current implementation of x-axis autohide is still controlled by the
widget, not the component, even if some of the code is shared. Components
are, again, only responsible for drawing (at least for now). For that
matter, the graph component does not have mutable access to any form of
state outside of tui-rs' `Frame`. Note this *might* change in the
future, where we might give the component state.

Note that while functionally, the graph behaviour for now is basically
the same, a few changes were made internally other than the move to
components. The big change is that rather than using tui-rs' `Chart`
for the underlying drawing, we now use a tweaked custom `TimeChart`
tui-rs widget, which also handles all interpolation steps and some extra
customization. Personally, I don't like having to deviate from the
library's implementation, but this gives us more flexibility and allows
greater control. For example, this allows me to move away from the old
hacks required to do interpolation (where I had to mutate the existing
list to avoid having to reallocate an extra vector just to insert one
extra interpolated point). I can also finally allow customizable
legends (which will be added in the future).
2022-04-28 23:36:53 -04:00
Clement Tsang 476a4ad910
deps: update dependencies (#713)
Updates various dependencies in both Cargo.toml and Cargo.lock.
2022-04-27 19:23:34 -04:00
Clement Tsang f2b8b4e842
other: add manpage file to cargo deb config, move back to build script (#693)
Adds the asset for the manpage to cargo deb config. Also moves the generated manpage file to a .1.gz file. Also, moves back to a build script since that was causing some issues for the automatic Cargo.toml fields detection for manpage and completion generation.

To prevent compilation from happening every time, and only in CI, we use an env var to avoid generation steps.
2022-03-11 06:45:05 -05:00