Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fuchs-fabian/simbashlog-discord-notifier
simbashlog-notifier for discord.com
https://github.com/fuchs-fabian/simbashlog-discord-notifier
discord discord-py linux logging logging-framework notifier simbashlog simbashlog-notifier
Last synced: about 1 month ago
JSON representation
simbashlog-notifier for discord.com
- Host: GitHub
- URL: https://github.com/fuchs-fabian/simbashlog-discord-notifier
- Owner: fuchs-fabian
- License: gpl-3.0
- Created: 2024-09-29T21:08:33.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-11-24T14:51:23.000Z (about 1 month ago)
- Last Synced: 2024-11-24T15:31:41.571Z (about 1 month ago)
- Topics: discord, discord-py, linux, logging, logging-framework, notifier, simbashlog, simbashlog-notifier
- Language: Python
- Homepage: https://github.com/fuchs-fabian/simbashlog/wiki
- Size: 55.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# `simbashlog-discord-notifier`: `simbashlog`-notifier for [discord.com](https://discord.com)
## Description
This is a `simbashlog`-notifier for [Discord](https://discord.com).
It uses the [Discord Webhook](https://discord.com/developers/docs/resources/webhook) to send messages to a Discord channel.
### Example message
![Example message](./example_message.png)
## Getting Started
> It is possible that `pip` is not yet installed. If this is not the case, you will be prompted to install it. Confirm the installation.
### Installation with `pip` (GitHub)
```bash
pip install git+https://github.com/fuchs-fabian/simbashlog-discord-notifier
```### Installation with `pip` (Local)
Download the repository and navigate to the directory containing the [`setup.py`](setup.py) file.
```bash
pip install .
```### Check Installation
```bash
pip list
``````bash
pip show simbashlog-discord-notifier
```### Configuration
After installation, you will find the configuration file under:
```plain
~/.config/simbashlog-notifier/simbashlog-discord-notifier/config.json
```This configuration file is used by default if no other custom configuration file is specified.
It looks as follows:
```json
{
"min_required_log_level": "6",
"show_in_console_sent_message": "true",
"show_in_header_pid": "false",
"show_in_body_log_file_result": "false",
"show_in_body_log_file_content": "false",
"show_in_body_summary_for_pid": "false",
"show_in_body_summary_for_log_file": "false",
"show_in_footer_log_file_names": "false",
"show_in_footer_host": "false",
"show_in_footer_notifier_name": "true",
"webhook_url": "https://discord.com/api/webhooks/...",
}
```### Usage
```plain
usage: simbashlog-discord-notifier [-h] [--config CONFIG] [--pid PID] [--log-level LOG_LEVEL] [--message MESSAGE] [--log-file LOG_FILE]
[--json-log-file JSON_LOG_FILE]Notifier for simbashlog.
options:
-h, --help show this help message and exit
--config CONFIG Path to a custom config file.
--pid PID The used process ID.
--log-level LOG_LEVEL
The used log level (sourced simbashlog) / severity number (simbashlog called with arguments).
--message MESSAGE The logged message (simbashlog called with arguments).
--log-file LOG_FILE The created *.log file.
--json-log-file JSON_LOG_FILE
The created *_log.json file.
```### Uninstallation
```bash
pip uninstall simbashlog-discord-notifier
```## Bugs, Suggestions, Feedback, and Needed Support
> If you have any bugs, suggestions or feedback, feel free to create an issue or create a pull request with your changes.
## Support `simbashlog`
If you like `simbashlog`'s ecosystem, you think it is useful and saves you a lot of work and nerves and lets you sleep better, please give it a star and consider donating.
---
> This script is a component of [`simbashlog`](https://github.com/fuchs-fabian/simbashlog) ([LICENSE](https://github.com/fuchs-fabian/simbashlog/blob/main/LICENSE)).
>
> The core of this notifier is [`simbashlog-notify-helper-py`](https://github.com/fuchs-fabian/simbashlog-notify-helper-py) ([LICENSE](https://github.com/fuchs-fabian/simbashlog-notify-helper-py/blob/main/LICENSE)).
>
> *Copyright (C) 2024 Fabian Fuchs*