Skip to content

Instantly share code, notes, and snippets.

View RouNNdeL's full-sized avatar
:shipit:

Krzysztof Zdulski RouNNdeL

:shipit:
  • Warsaw
View GitHub Profile
@RouNNdeL
RouNNdeL / dnsmasq.chart.py
Last active August 23, 2019 10:21
dnsmasq python.d plugin for netdata
from bases.FrameworkServices.LogService import LogService
import os
ORDER = ['dns_query']
CHARTS = {
"dns_query": {
'options': [None, 'DNS Queries', 'responses/s', 'responses', 'dnsmasq_log.dns_query', 'line'],
'lines': [
['successful_query', 'success', 'absolute'],
['query_errors', 'error', 'absolute'],
@RouNNdeL
RouNNdeL / steam.chart.py
Created August 20, 2018 17:21
Steam services ping netdata python.d plugin. Uses NetworkDatagramConfig.json from SteamDatabase to fetch the server IPs
#!/usr/bin/python
from bases.FrameworkServices.SimpleService import SimpleService
import os
import json
import ipaddress
import random
import subprocess
import re
FPING_REGEX = r"(\S*)\s+: ([\d.]+|-)"
@RouNNdeL
RouNNdeL / LICENSE
Last active July 10, 2024 20:48
Lua script for Game Guardian for Geomatery Dash allowing to fly over a level
MIT License
Copyright (c) 2019 Krzysztof "RouNdeL" Zdulski
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
@RouNNdeL
RouNNdeL / better_random.user.js
Last active January 3, 2023 03:37
Interpolated roll for Google's random number generator
// ==UserScript==
// @name Better Random Number
// @version 1.3
// @description Interpolated roll for Google's random number generator
// @author RouNdeL
// @match https://www.google.pl/search*
// @match https://www.google.com/search*
// @require http://code.jquery.com/jquery-3.3.1.min.js
// @resource customCSS https://home.zdul.xyz/material_select.css?v=1
// @grant GM_addStyle
@RouNNdeL
RouNNdeL / net_throttle.sh
Last active July 23, 2019 13:00
Linux tc throttling script
#!/bin/bash
# Copyright 2019 Krzysztof "RouNdeL" Zdulski
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software
# and associated documentation files (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, modify, merge, publish, distribute,
# sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
@RouNNdeL
RouNNdeL / diamond.py
Last active October 31, 2018 21:58
Diamond in Python
def diamond(n):
half = n/2
print(half * " " + "*")
r = range(1, half + n % 2)+range(half-1, 0, -1)
for i in r:
print((half - i) * " " + "*" + (2*i-1) * " " + "*")
print(half * " " + "*")
@RouNNdeL
RouNNdeL / messenger_export.js
Created November 29, 2018 20:08
Very flimsy script to export a Messenger Group user list. (Requires jQuery)
const users = [];
const li = $("div[data-testid='info_panel']").find("h4:contains('People')").eq(0).siblings().eq(1).find("li").each(function(){
const text = $(this).text();
users.push(text.replace(/^(Admin|Administrator)/, ""));
});
console.log(users.join("\n"));
@RouNNdeL
RouNNdeL / m49_regions.json
Created February 9, 2019 11:55
M49 Region List
{
"142": {
"name": "Asia",
"sub": {
"143": {
"name": "Central Asia",
"countries": [
"TM",
"TJ",
"KG",
@RouNNdeL
RouNNdeL / geolocation.js
Created February 9, 2019 11:57
Node.js file that updates my IP Geolocation list using https://ipstack.com/ API
/*
* MIT License
*
* Copyright (c) 2019 Krzysztof "RouNdeL" Zdulski
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@RouNNdeL
RouNNdeL / ble_current_time.js
Last active November 2, 2019 16:38
Generate BLE standard compliant org.bluetooth.characteristic.current_time characteristic value
/**
* Generate a BLE compliant org.bluetooth.characteristic.current_time characteristic value
*
* @param {Date} date
* @param {Number} reason
*/
function getBleTime(date, reason = 1) {
let str = "";
str += date.getFullYear().toString(16).padStart(4, "0").match(/[a-fA-F0-9]{2}/g).reverse().join('');