An external xmobar plugin for customizable weather info!
Project description
Prerequisites
This program mainly uses following python3 modules
- requests
- pyyaml
Install
pip install xmobar-wttr
For installing from source, clone the repository, and run
cd xmobar_wttr
python setup.py install
or create a virtual environment with
pipenv install
pipenv install -e .
To activate the virtual environment run
pipenv shell
or start every command with pipenv run
.
Usage
usage: xmobar_wttr [-h] [-c <path>] [-l <loc>] [-f <format>] [-o <path>] [-s <section>] [-p <par-list> [<par-list> ...]] [-v]
optional arguments:
-h, --help show this help message and exit
-c <path>, --config <path>
Path to the config file
-l <loc>, --location <loc>
Location for which to pull information.
-f <format>, --format <format>
Format template for xmobarrc
-o <path>, --output <path>
Path to the output file
-s <section>, --section <section>
Section in the yaml file to be parsed
-p <par-list> [<par-list> ...], --pars <par-list> [<par-list> ...]
Select parameters to be fetched from wttr.in
excluded parameters are not available in xmobar template format
-v, --verbose Run program in verbose mode
Configuration
xmobar_wttr
works with both command-line arguments as well as YAML
configuration files (the first takes precedence over the latter). To
set your desired defaults edit the configuration file
xmobar_wttr.yml
and place it in either
~/.config/xmobar_wttr/xmobar_wttr.yml
~/.config/xmobar/xmobar_wttr.yml
~/.xmobar_wttr/xmobar_wttr.yml
~/.xmobar_wttr.yml
Notation
Notation | \*Description |
---|---|
%[par] | parameter value |
%g[par] | render parameter only as icon |
%G[par] | prefix icon to parameter value |
.u | append units of previous parameter |
Format map | Result |
---|---|
<2:…> | … |
{#dedede:…} | … |
\\… | \x… |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
xmobar_wttr-0.0.dev3.tar.gz
(22.8 kB
view details)
File details
Details for the file xmobar_wttr-0.0.dev3.tar.gz
.
File metadata
- Download URL: xmobar_wttr-0.0.dev3.tar.gz
- Upload date:
- Size: 22.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.0.1 pkginfo/1.8.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a8bd9e809f7b249bfa663f78707803dd4aacc6dd670714edea817ef8f2693353 |
|
MD5 | 45dc73364fb444f8b6c22af0826bc097 |
|
BLAKE2b-256 | f0af73934c7e4cabcb7bcf12e857da710c60c0a9c0f32fed2eab5c0aca141be9 |