Skip to content

Instantly share code, notes, and snippets.

from queue import Queue
from threading import Thread
from typing import Callable, Iterable
def job_worker(jobs: Queue, results: list):
while not jobs.empty():
job = jobs.get()
results.append(job())
jobs.task_done()
@ruby0b
ruby0b / fancy_taglist.lua
Created May 26, 2022 18:34 — forked from intrntbrn/fancy_taglist.lua
awesomewm fancy_taglist: a taglist that contains a tasklist for each tag
-- awesomewm fancy_taglist: a taglist that contains a tasklist for each tag.
-- Usage (add s.mytaglist to the wibar):
-- awful.screen.connect_for_each_screen(function(s)
-- ...
-- local fancy_taglist = require("fancy_taglist")
-- s.mytaglist = fancy_taglist.new({
-- screen = s,
-- taglist = { buttons = mytagbuttons },
-- tasklist = { buttons = mytasklistbuttons }
-- })