/my-bitbar-scripts

My BitBar scripts.

Primary LanguagePythonMIT LicenseMIT

My BitBar Scripts

Here are my Python scripts and a library for BitBar.

Usage

Create a soft link from scripts to enabled

ln -s scripts/XXX.py enabled/XXX.??m.py

or just copy it there.

The Library

The libs/bitbar.py automates the generation of output.

Simply create a BitBarMessagePack and append() any message to it, attributes like color, font or href is attached as a dict.

Examples

Further examples refer to published scripts.

Multi-line plugin with extra data

#!/bin/bash
echo "One"
echo "Two"
echo "Three"
echo "---"
echo "Four"
echo "Five"
echo "Six"

equals

pkg = BitBarMessagePack("One\nTwo\nThree")
echo "---"
pkg.append("Four")
pkg.append(Five")
pkg.append("Six")

Scripts

📺 Slurm Queue

List Slurm queue on a HPC.

Requires

fabric

Edit

user = "USER"
server = "example.com"
prefix = ""

🦠 nCov-2019 Statistics in NYC

Data from NYCHealth-ncov.

😷 nCov-2019 Statistics in China

数据来源丁香园