Skip to content

Instantly share code, notes, and snippets.

Avatar
:octocat:

Sergej Müller sergejmueller

:octocat:
View GitHub Profile
@sergejmueller
sergejmueller / vat_rates.php
Last active Jul 24, 2020
List of EU Countries (ISO-3166-2) with equivalent VAT Rates
View vat_rates.php
$vat_rates = array(
'AT' => 20, // Austria
'BE' => 21, // Belgium
'BG' => 20, // Bulgaria
'HR' => 25, // Croatia
'CY' => 19, // Cyprus
'CZ' => 21, // Czech Republic
'DK' => 25, // Denmark
'EE' => 20, // Estonia
'FI' => 24, // Finland
@sergejmueller
sergejmueller / ttf2woff2.md
Last active Jul 7, 2020
WOFF 2.0 – Learn more about the next generation Web Font Format and convert TTF to WOFF2
View ttf2woff2.md
@sergejmueller
sergejmueller / nginx.conf
Last active Jun 4, 2020
Stop search engines from indexing .txt, .log, .xml, .css and .js files in Nginx
View nginx.conf
location ~* \.(txt|log|xml|css|js)$ {
add_header X-Robots-Tag noindex;
}
@sergejmueller
sergejmueller / mime.types
Created Nov 27, 2013
Nginx: Detecting WebP support with Header Vary Accept. Filename format: image.jpeg / image.webp
View mime.types
...
image/webp webp;
...
@sergejmueller
sergejmueller / index.html
Created Feb 21, 2020
Radio fields check and uncheck
View index.html
<input type="radio" name="1" class="radio">
<input type="radio" name="1" class="radio">
<input type="radio" name="1" class="radio">
<input type="radio" name="1" class="radio">
<br>
<input type="radio" name="2" class="radio">
<input type="radio" name="2" class="radio">
<input type="radio" name="2" class="radio">
<input type="radio" name="2" class="radio">
@sergejmueller
sergejmueller / selfpv_energy.ino
Created May 3, 2017
ESP8266 + SSD1306 FRITZ!Box API
View selfpv_energy.ino
/*
* ESP8266 + SSD1306 ♥ FRITZ!Box API
*
* Ausgabe der aktuell über die FRITZ!DECT 200 Steckdose
* entnommenen Leistung als Prozentwert auf einem SSD1306 OLED Display.
* Praxisbeispiel: Durch die Solaranlage eingespeiste Leistung abrufen
* und auf dem OLED Display in Form eines Prozentwertes einblenden.
*
* Referenzen:
* http://www.instructables.com/id/Wemos-D1-Mini-096-SSD1306-OLED-Display-Using-SPI/
@sergejmueller
sergejmueller / README.md
Last active Dec 15, 2019
NVIDIA GPUs Monitoring + Remote Dashboards (for each GPU)
View README.md

Monitor anytime and anywhere your installed NVIDIA GPUs with permanent sync to dweet.io - a remote public dashboard for each GPU.

Features

  • No setup, no registration, easy to use Batch file
  • List of installed cards with their current properties
  • Display average properties
  • Push the single GPU data to dweet.io (can be disabled by remoteDashboardActive)
  • Auto refresh every 30 seconds (can be changed by refreshInterval)
  • One remote dashboard for each GPU
@sergejmueller
sergejmueller / .htaccess
Last active Dec 10, 2019
Apache: Detecting WebP support with Header Vary Accept
View .htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_ACCEPT} image/webp
RewriteCond %{DOCUMENT_ROOT}/$1.webp -f
RewriteRule (.+)\.(jpe?g|png)$ $1.webp [T=image/webp,E=accept:1]
</IfModule>
<IfModule mod_headers.c>
Header append Vary Accept env=REDIRECT_accept
</IfModule>
@sergejmueller
sergejmueller / gist:088dce028b6dd120a16e
Last active Nov 14, 2019
mozjpeg vs. libjpeg-turbo – Output File Size and Execution Time
View gist:088dce028b6dd120a16e

Lossless and progressive optimization of multiple (random picked, less than 1 MB) JPEG images with mozjpeg 2.0 and libjpeg-turbo.

Original Size mozjpeg Size libjpeg-turbo Size mozjpeg Speed libjpeg-turbo Speed
621 KB 612 KB 615 KB 0.658 s 0.297 s
505 KB 475 KB 477 KB 0.481 s 0.204 s
391 KB 376 KB 385 KB 0.846 s 0.441 s
888 KB 780 KB 794 KB 0.786 s 0.346 s
700 KB 668 KB 670 KB 0.765 s 0.320 s
@sergejmueller
sergejmueller / comodo.pem
Created Feb 13, 2015
OCSP stapling PEM file for Comodo certificates used on Nginx.
View comodo.pem
-----BEGIN CERTIFICATE-----
MIIGCDCCA/CgAwIBAgIQKy5u6tl1NmwUim7bo3yMBzANBgkqhkiG9w0BAQwFADCB
hTELMAkGA1UEBhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G
A1UEBxMHU2FsZm9yZDEaMBgGA1UEChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNV
BAMTIkNPTU9ETyBSU0EgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkwHhcNMTQwMjEy
MDAwMDAwWhcNMjkwMjExMjM1OTU5WjCBkDELMAkGA1UEBhMCR0IxGzAZBgNVBAgT
EkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UEChMR
Q09NT0RPIENBIExpbWl0ZWQxNjA0BgNVBAMTLUNPTU9ETyBSU0EgRG9tYWluIFZh
bGlkYXRpb24gU2VjdXJlIFNlcnZlciBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEP
ADCCAQoCggEBAI7CAhnhoFmk6zg1jSz9AdDTScBkxwtiBUUWOqigwAwCfx3M28Sh
You can’t perform that action at this time.