Skip to content

Instantly share code, notes, and snippets.

View brodul's full-sized avatar

Andraz Brodnik brodul

View GitHub Profile
@brodul
brodul / postne.json
Last active March 4, 2024 14:06
Postne stevilke
[{"number": 8341, "name": "Adlešiči"}, {"number": 5270, "name": "Ajdovščina"}, {"number": 6280, "name": "Ankaran/Ancarano"}, {"number": 9253, "name": "Apače"}, {"number": 8253, "name": "Artiče"}, {"number": 4275, "name": "Begunje na Gorenjskem"}, {"number": 1382, "name": "Begunje pri Cerknici"}, {"number": 9231, "name": "Beltinci"}, {"number": 2234, "name": "Benedikt"}, {"number": 2345, "name": "Bistrica ob Dravi"}, {"number": 3256, "name": "Bistrica ob Sotli"}, {"number": 8259, "name": "Bizeljsko"}, {"number": 1223, "name": "Blagovica"}, {"number": 8283, "name": "Blanca"}, {"number": 4260, "name": "Bled"}, {"number": 4273, "name": "Blejska Dobrava"}, {"number": 9265, "name": "Bodonci"}, {"number": 9222, "name": "Bogojina"}, {"number": 4263, "name": "Bohinjska Bela"}, {"number": 4264, "name": "Bohinjska Bistrica"}, {"number": 4265, "name": "Bohinjsko jezero"}, {"number": 1353, "name": "Borovnica"}, {"number": 8294, "name": "Boštanj"}, {"number": 5230, "name": "Bovec"}, {"number": 5295, "name": "Branik"}, {"nu
@brodul
brodul / index.html
Last active July 15, 2021 07:05
closures presentation
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>@brodul</title>
<link rel="stylesheet" href="dist/reset.css">
-----BEGIN PGP MESSAGE-----
hQIMA4Ey4yWmnclQARAAzBNg/7bPiex2avGPlbB0P3Dg4pU5w2Ab6yGCg3QecQk6
X3XSzFNtQ6cIIEX8aa+Kzeg1egsku41/HbfsRwbQTrp9syiFJcW0OCiPJ8x7+JUY
oLCvZ7Zn/C48Hrf+2w+OIezMdkUuUDo3ujiXHz/DOdEhUzT6X2B0zrFi7bV7rhkD
Ca9nDTkLOC87bjEXKwczlRGqvG2pOPnYou7THoydqhfMwaBzG+cxBXSSxaVH5CIF
h/qG+/3/4jE6zd6MealQq7+hsq/8w5spYulAQdqqwPizVSaj+MZj86bBId0mNs8R
UQy8o5DO8oPHuApYNqg5bpmOnrK1fcgvXNp63BdJJoLriFD3aA0KZETfRTClGqOD
D2MPy3JaDIBYOMDkErW0JraxC32TtXAUZy9ovupiRxRMdkHaUnHnviDRwStOGQtd
OHGrpSdb+GsXdQiqtVdAPr4c9VOowPJg6JZcOfIlONuyb63GRcph8lzEeHv66amD
// ==UserScript==
// @name Huble Bundle Books
// @namespace http://brodul.org
// @version 0.1
// @description Downloads books in a format from huble bundle
// @author Andraz Brodnik brodul
// @match https://www.humblebundle.com/*
// @grant GM_download
// @run-at document-idle
// ==/UserScript==
@brodul
brodul / Makefile
Created August 26, 2020 06:50
python Makefile
SHELL= bash
VENV = venv
install: requirements.txt
python3 -m venv $(VENV)
$(VENV)/bin/pip install -r requirements.txt --upgrade
clean:
rm -rf $(VENV)
@brodul
brodul / basic_wrapping.py
Last active January 4, 2020 11:55
concurrency in python in 2020
import urllib.request
import asyncio
loop = asyncio.get_event_loop()
loop.set_debug(True)
def get(url):
with urllib.request.urlopen(url) as f:
return f.read()
time="2018-01-16T21:16:01Z" level=error msg="Error getting ACME certificates [last-push.example.com] : cannot obtain certificates map[last-push.example.com:acme: Error 429 - urn:acme:error:rateLimited - Error creating new authz :: too many fa
iled authorizations recently: see https://letsencrypt.org/docs/rate-limits/]"
time="2018-01-17T09:25:04Z" level=error msg="map[develop.1.example.com:acme: Error 403 - urn:acme:error:unauthorized - Invalid response from http://develop.1.example.com/.well-known/acme-challenge/8TGpwog-LKOdXLRFxcKVBVLqv1MJlJd1r34aY7WeDXM:
"
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Page not"
graceTimeOut = "10s"
checkNewVersion = false
defaultEntryPoints = ["http", "https"]
[entryPoints]
[entryPoints.http]
address = ":80"
[entryPoints.http.redirect]
entryPoint = "https"
[entryPoints.https]
address = ":443"
time="2018-01-16T15:36:16Z" level=error msg="map[last-push.example.com:acme: Error 429 - urn:acme:error:rateLimited - Error creating new authz :: too many failed authorizations recently: see https://letsencrypt.org/docs/rate-limits/]"
time="2018-01-16T15:36:16Z" level=error msg="Error getting ACME certificates [last-push.example.com] : cannot obtain certificates map[last-push.example.com:acme: Error 429 - urn:acme:error:rateLimited - Error creating new authz :: too many failed authorizations recently: see https://letsencrypt.org/docs/rate-limits/]"
time="2018-01-16T15:36:20Z" level=error msg="map[last-push.1.example.com:acme: Error 403 - urn:acme:error:unauthorized - Invalid response from http://last-push.1.example.com/.well-known/acme-challenge/-NdWyrjogM19ohD5-2GAgiVQjwDuGl2Jk5ZJ8i3cpi0: "
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Page not"
Error Detail:
Validation for last-push.1.example.com:443
brodul:~/ $ espeak [11:17:59]
a
ALSA lib pcm.c:2521:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2521:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2521:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:867:(find_matching_chmap) Found no matching channel map
ALSA lib pcm.c:2442:(snd_pcm_open_conf) Either /nix/store/bmqqdmp9jajmx8v5jwc4lxl62b6apynm-alsa-plugins-1.1.5/lib/alsa-lib/libasound_module_pcm_pulse.so cannot be opened or _snd_pcm_pulse_open was not defined inside