This repository has been archived on 2025-03-19. You can view files and clone it, but cannot push or open issues or pull requests.
gowaybarplug/debian/control
2024-06-11 15:30:57 -06:00

66 lines
1.7 KiB
Text

Source: golang-github-lack-gowaybarplug
Section: golang
Priority: optional
Maintainer: Penelope Gwen <support@pogmom.me>
Uploaders: Penelope Gwen <support@pogmom.me>
Rules-Requires-Root: no
Build-Depends: debhelper-compat (= 13),
dh-sequence-golang,
golang-any,
golang-github-stretchr-testify-dev,
golang-github-xorcare-pointer-dev
Testsuite: autopkgtest-pkg-go
Standards-Version: 4.6.2
Homepage: https://git.pogmom.me/pogmommy/gowaybarplug
XS-Go-Import-Path: github.com/lack/gowaybarplug
Package: golang-github-lack-gowaybarplug-dev
Architecture: all
Multi-Arch: foreign
Depends: golang-github-stretchr-testify-dev,
golang-github-xorcare-pointer-dev,
${misc:Depends}
Description: Go framework for custom waybar plugins (library)
gowaybarplug
.
Go framework for custom Waybar (https://github.com/Alexays/Waybar)
plugins
.
Usage
.
First build a plugin that reports some interesting status:
.
package main
.
import (
"time"
.
waybar "github.com/lack/gowaybarplug"
)
.
main() {
updater := waybar.NewUpdater()
for {
status := waybar.Status{
Text: "Some text",
Toolbar: "Other text",
}
// Obviously do something more interesting than just static
text in the status...
updater.Status <- &status
time.Sleep(15 * time.Second)
}
}
.
Then add it to your ~/.config/waybar/config:
.
{
// ... Other waybar config
"custom/mything": {
"format": "{} {icon}",
"return-type": "json",
"exec": "/path/to/my/new/plugin"
// etc
}
}