Add tmux-clima as another module for weather (#161)
* Add tmux-clima as a module * Update tmux option names according to the clima module * Add README for tmux-clima * Update README.md according to suggestions * Remove unnecessary readme part --------- Co-authored-by: vdbewout <vdbewout@gmail.com>
This commit is contained in:
parent
c0861b7861
commit
d0371badc7
2 changed files with 39 additions and 5 deletions
33
README.md
33
README.md
|
|
@ -29,7 +29,7 @@
|
||||||
5. [Customizing modules](#customizing-modules)
|
5. [Customizing modules](#customizing-modules)
|
||||||
6. [Battery module](#battery-module)
|
6. [Battery module](#battery-module)
|
||||||
7. [CPU module](#CPU-module)
|
7. [CPU module](#CPU-module)
|
||||||
8. [Weather module](#weather-module)
|
8. [Weather modules](#weather-modules)
|
||||||
9. [Load module](#load-module)
|
9. [Load module](#load-module)
|
||||||
10. [Uptime module](#uptime-module)
|
10. [Uptime module](#uptime-module)
|
||||||
5. [Create a custom module](#create-a-custom-module)
|
5. [Create a custom module](#create-a-custom-module)
|
||||||
|
|
@ -373,15 +373,17 @@ Add the cpu module to the status modules list.
|
||||||
set -g @catppuccin_status_modules_right "... cpu ..."
|
set -g @catppuccin_status_modules_right "... cpu ..."
|
||||||
```
|
```
|
||||||
|
|
||||||
### Weather module
|
### Weather modules
|
||||||
|
|
||||||
#### Requirements
|
#### tmux-weather
|
||||||
|
|
||||||
|
##### Requirements
|
||||||
This module depends on [tmux-weather](https://github.com/xamut/tmux-weather).
|
This module depends on [tmux-weather](https://github.com/xamut/tmux-weather).
|
||||||
|
|
||||||
#### Install
|
##### Install
|
||||||
The preferred way to install tmux-weather is using [TPM](https://github.com/tmux-plugins/tpm).
|
The preferred way to install tmux-weather is using [TPM](https://github.com/tmux-plugins/tpm).
|
||||||
|
|
||||||
#### Configure
|
##### Configure
|
||||||
Load tmux-weather after you load catppuccin.
|
Load tmux-weather after you load catppuccin.
|
||||||
```sh
|
```sh
|
||||||
set -g @plugin 'catppuccin/tmux'
|
set -g @plugin 'catppuccin/tmux'
|
||||||
|
|
@ -394,6 +396,27 @@ Add the weather module to the status modules list.
|
||||||
set -g @catppuccin_status_modules_right "... weather ..."
|
set -g @catppuccin_status_modules_right "... weather ..."
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### tmux-clima
|
||||||
|
|
||||||
|
##### Requirements
|
||||||
|
This module depends on [tmux-clima](https://github.com/vascomfnunes/tmux-clima).
|
||||||
|
|
||||||
|
##### Install
|
||||||
|
The preferred way to install tmux-clima is using [TPM](https://github.com/tmux-plugins/tpm).
|
||||||
|
|
||||||
|
##### Configure
|
||||||
|
Load tmux-clima after you load catppuccin.
|
||||||
|
```sh
|
||||||
|
set -g @plugin 'catppuccin/tmux'
|
||||||
|
...
|
||||||
|
set -g @plugin 'vascomfnunes/tmux-clima'
|
||||||
|
```
|
||||||
|
|
||||||
|
Add the weather module to the status modules list.
|
||||||
|
```sh
|
||||||
|
set -g @catppuccin_status_modules_right "... clima ..."
|
||||||
|
```
|
||||||
|
|
||||||
### Load module
|
### Load module
|
||||||
|
|
||||||
#### Requirements
|
#### Requirements
|
||||||
|
|
|
||||||
11
status/clima.sh
Normal file
11
status/clima.sh
Normal file
|
|
@ -0,0 +1,11 @@
|
||||||
|
# Requires https://github.com/vascomfnunes/tmux-clima
|
||||||
|
show_clima() {
|
||||||
|
local index=$1
|
||||||
|
local icon="$(get_tmux_option "@catppuccin_clima_icon" "")"
|
||||||
|
local color="$(get_tmux_option "@catppuccin_clima_color" "$thm_yellow")"
|
||||||
|
local text="$(get_tmux_option "@catppuccin_clima_text" "#{clima}")"
|
||||||
|
|
||||||
|
local module=$( build_status_module "$index" "$icon" "$color" "$text" )
|
||||||
|
|
||||||
|
echo "$module"
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue