From 3442864fbecd9a06a4f7add6f5489e7e63fc817d Mon Sep 17 00:00:00 2001 From: Arindy Date: Sun, 28 Dec 2025 15:20:07 +0100 Subject: [PATCH] Add templates, README, and license to initialize project essentials --- LICENSE | 21 ++++++++++++ README.md | 72 ++++++++++++++++++++++++++++++++++++++++++ devices_template.json | 9 ++++++ websites_template.json | 10 ++++++ 4 files changed, 112 insertions(+) create mode 100644 LICENSE create mode 100644 README.md create mode 100644 devices_template.json create mode 100644 websites_template.json diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..5469edf --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2025 Arindy + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..00b6d4d --- /dev/null +++ b/README.md @@ -0,0 +1,72 @@ +# ArinDash + +ArinDash is a customizable terminal dashboard (TUI) written in Go, powered by [`termdash`](https://github.com/mum4k/termdash). It allows you to monitor various services, network devices, and system information in a single terminal view. + +## Features + +- **Clock & Date**: Real-time time and date display. +- **Pi-hole Integration**: Monitor your Pi-hole statistics, including query counts and blocked percentages. +- **Docker Monitoring**: View the status of your Docker containers. +- **HTTP Prober**: Check the availability and status codes of your favorite websites. +- **Network Device Monitoring**: Track which devices are online in your local network. +- **WiFi QR Code**: Display a QR code for easy WiFi connection sharing. +- **Interactive TUI**: Built with `termdash` for a responsive and visually appealing terminal interface. + +## Prerequisites + +- **Go**: Version 1.25.5 or later. +- **Docker**: If you want to use the Docker monitoring widget. +- **Nerd Fonts**: Recommended for displaying icons correctly in the terminal. You can find icons at the [Nerd Fonts Cheat Sheet](https://www.nerdfonts.com/cheat-sheet). + +## Installation + +1. Clone the repository: + ```bash + git clone https://github.com/yourusername/ArinDash.git + cd ArinDash + ``` + +2. Install dependencies: + ```bash + go mod download + ``` + +## Configuration + +ArinDash uses a `config.toml` file for its settings. A template is provided as `config_template.toml`. + +1. Copy the template: + ```bash + cp config_template.toml config.toml + ``` + +2. Edit `config.toml` with your specific details: + - **Pi-hole**: Set your host and API password. + - **WiFi**: Configure your SSID and password for the QR code widget. + +3. Customize widgets: + - **Websites**: Copy `websites_template.json` to `websites.json` and update it with the URLs and icons you want to monitor. + - **Network Devices**: Copy `devices_template.json` to `devices.json` and configure it with the MAC addresses and names of the devices you want to track. + +## Usage + +To run ArinDash, simply execute: + +```bash +go run main.go +``` + +### Controls +- **Esc / Ctrl+C**: Exit the application. + +## Project Structure + +- `main.go`: Entry point and layout definition. +- `widgets/`: Contains individual widget implementations (Clock, Docker, Pi-hole, etc.). +- `apis/`: API clients for interacting with external services (Docker, Pi-hole, etc.). +- `config/`: Configuration loading logic. +- `util/`: Helper functions and utilities. + +## License + +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. diff --git a/devices_template.json b/devices_template.json new file mode 100644 index 0000000..d96dd95 --- /dev/null +++ b/devices_template.json @@ -0,0 +1,9 @@ +{ + "00:00:00:00:00:00": { + "name": "Sample Device", + "ip": "192.168.1.10", + "interface": "", + "icon": "󰄜", + "online": false + } +} diff --git a/websites_template.json b/websites_template.json new file mode 100644 index 0000000..11e3e03 --- /dev/null +++ b/websites_template.json @@ -0,0 +1,10 @@ +[ + { + "url": "https://google.com", + "icon": "󰊭" + }, + { + "url": "https://github.com", + "icon": "󰊤" + } +]