Skip to content

Instantly share code, notes, and snippets.

View dz0ny's full-sized avatar
💭
❤️✖️❓🤖

Janez Troha dz0ny

💭
❤️✖️❓🤖
View GitHub Profile
diff all
# version
# INAV/ATOMRCF405NAVI 7.1.0 Feb 14 2024 / 14:10:39 (49325426)
# GCC-10.3.1 20210824 (release)
# start the command batch
batch start
# reset configuration to default settings
@dz0ny
dz0ny / Readme.md
Last active November 3, 2023 10:31
@dz0ny
dz0ny / vreme.si-cache.js
Created July 18, 2023 20:35
Caching proxy za vreme.si
export default {
async fetch(request) {
let url = new URL(request.url);
url.hostname = "www.vreme.si";
let newRequest = new Request(url, request);
let response = await fetch(newRequest, {
cf: {
cacheTtl: 60,
cacheEverything: true,
@dz0ny
dz0ny / mopidy.liq
Last active May 9, 2023 12:39
Gapless streaming for mopidy
#!/usr/bin/liquidsoap
set("log.file.path", "/dev/null")
set("log.stdout", true)
set("server.telnet", false)
set("harbor.bind_addr","0.0.0.0")
# tweak these values if you have lag, skipping, buffer underrun etc
# set("frame.duration",0.04)
# set("root.max_latency",60.)
@dz0ny
dz0ny / svg.conf
Created February 29, 2012 19:54
Nginx svg
location ~* \.svg$ {
default_type image/svg+xml;
# caching za procy in server odstrani ce ne zelis
expires max;
add_header Pragma public;
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
}
@dz0ny
dz0ny / printer-prusa-mk3s-2021-bondtech.cfg
Last active March 3, 2023 09:08 — forked from nikolak/printer-prusa-mk3s-2021.cfg
Klipper MK3S/+ Config including optional Bondtech Extruder, Bear Extruder, etc.
# This file contains pin mappings and reasonable defaults for Prusa i3 MK3S
# printers. It will work with MK3 (non-S) by selecting the alternative filament
# sensor. References to common community mods are included as well.
#
[include mainsail.cfg]
[skew_correction]
[force_move]
addEventListener("fetch", (event) => {
event.respondWith(handleRequest(event.request));
});
function handleOptions(request) {
// Make sure the necessary headers are present
// for this to be a valid pre-flight request
let headers = request.headers;
if (
headers.get("Origin") !== null &&
@dz0ny
dz0ny / arso15m.py
Last active November 2, 2022 08:37
Swiftbar ARSO
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# <bitbar.title>Vreme ARSO</bitbar.title>
# <bitbar.version>v1.0.2</bitbar.version>
# <bitbar.author.github>dz0ny</bitbar.author.github>
import requests
from collections import namedtuple
from collections import OrderedDict
@dz0ny
dz0ny / ubuntu.sh
Created May 4, 2012 16:36
Ubuntu quick install (ninite like)
sudo sh -c 'echo "Great"'
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google.list'
wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -
sudo sh -c 'echo "deb http://download.virtualbox.org/virtualbox/debian precise contrib" > /etc/apt/sources.list.d/virtualbox.list'
sudo add-apt-repository ppa:webupd8team/sublime-text-2 -y
sudo add-apt-repository ppa:sgringwe/beatbox -y
sudo add-apt-repository ppa:jconti/recent-notifications -y
set osd_warn_core_temp = ON
set osd_warn_fail_safe = OFF
set osd_warn_rssi = OFF
set osd_rssi_alarm = 30
set osd_cap_alarm = 1200
set osd_alt_alarm = 400
set osd_rssi_pos = 2096
set osd_link_quality_pos = 2096
set osd_link_tx_power_pos = 352
set osd_tim_1_pos = 449