Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/beltex/dshb
macOS system monitor
https://github.com/beltex/dshb
cli monitoring swift
Last synced: 9 days ago
JSON representation
macOS system monitor
- Host: GitHub
- URL: https://github.com/beltex/dshb
- Owner: beltex
- License: mit
- Created: 2014-09-15T23:00:44.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2022-02-13T18:05:41.000Z (over 2 years ago)
- Last Synced: 2024-08-01T19:31:19.379Z (3 months ago)
- Topics: cli, monitoring, swift
- Language: Swift
- Homepage: https://beltex.github.io/dshb
- Size: 479 KB
- Stars: 472
- Watchers: 15
- Forks: 34
- Open Issues: 24
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-swift-cn - dshb - OS X system monitor in Swift. (Demo Apps / 示例程序 / OS X)
README
dshb
====A macOS system monitor in Swift, inspired by
top &
[htop](https://github.com/hishamhm/htop). Displays live readings of system CPU &
memory usage, machine temperature sensors, fan speeds, battery information and
other miscellaneous system statistics. The ncurses based TUI (text-based user
interface) uses color coating to imply status and is fully resizable. Stats are
updated at one second intervals while still maintaining low overhead (the
observer effect
is inescapable in this case sadly).![alt text](docs/dshb.png)
### Why?
- Exploration of Swift. In particular, systems programming and interfacing with
low-level C APIs### Homebrew :beer:
```sh
$ brew install dshb
```### Requirements
- [Xcode 8.3.3 (Swift 3.1)](https://developer.apple.com/xcode/downloads/)
- macOS 10.9+
- This is due to Swift### Clone
Make sure to use the recursive option on clone to auto init all submodules.
```sh
git clone --recursive https://github.com/beltex/dshb
```Incase you have already cloned the repository, run the following inside the
project directory.```sh
git submodule update --init
```### Install
This will build dshb from source and place the binary and manual page in your
path.```sh
make install
```### Stack
- [ncurses](https://www.gnu.org/software/ncurses/ncurses.html)
- For drawing to the terminal (tested with version 5.4 - default on macOS)
- [SystemKit](https://github.com/beltex/SystemKit)
- For almost all statistics
- [SMCKit](https://github.com/beltex/SMCKit)
- For temperature & fan statistics
- [CommandLine](https://github.com/jatoben/CommandLine)
- For the CLI
- [ronn](https://github.com/rtomayko/ronn)
- For generating the manual pageAll Git submodules are built part of the project as simply source files, not
frameworks (which are essentially dynamic libraries). This is because currently,
the Swift runtime dynamic libraries must be packaged with the application in
question. In the case of **dshb**, a single binary is generated which has the
runtime statically linked. Thus, frameworks, which expect to find the libraries
inside the application bundle (`.app`), cannot _"see"_ them.For more see:
- [SwiftInFlux/Runtime Dynamic Libraries](https://github.com/ksm/SwiftInFlux#runtime-dynamic-libraries)
- [SwiftInFlux/Static Libraries](https://github.com/ksm/SwiftInFlux#static-libraries)### References
- [top](http://www.opensource.apple.com/source/top/)
- [NCURSES Programming HOWTO](http://www.tldp.org/HOWTO/NCURSES-Programming-HOWTO/index.html)
- [Programmer's Guide to ncurses](http://www.c-for-dummies.com/ncurses/)
- [Writing Programs with NCURSES](http://invisible-island.net/ncurses/ncurses-intro.html)### License
This project is under the **MIT License**.
##### _P.S._
Working on this always brought a smile to my face. I hope it brings a smile to
yours too.
[Enjoy](http://hypem.com/track/23j7h/First+Aid+Kit+-+My+Silver+Lining) :)