Skip to content

Instantly share code, notes, and snippets.

@danielwagn3r
danielwagn3r / extend_head.html
Created March 14, 2023 16:00
Hugo Googly Analytics with cookie consent
<div id="cookie-notice">
<span>We would like to use third party cookies and scripts to improve the
functionality of this website.</span>
<a id="cookie-notice-accept" class="button">Accept</a>
<a id="cookie-notice-deny" class="button">No Thanks</a>
<a href="/privacy">More info</a>
</div>
<script>
function createCookie(name, value, days) {
@danielwagn3r
danielwagn3r / app.conf
Last active January 30, 2022 10:05
Nginx and Let’s Encrypt with Docker
types {
application/x-ns-proxy-autoconfig dat;
}
server {
listen 80;
server_name sub.example.com;
server_tokens off;
location / {
@danielwagn3r
danielwagn3r / log output after request to GUI
Last active April 17, 2021 18:40
linuxserver/docker-calibre
calibre_1 | -------------------------------------
calibre_1 | _ ()
calibre_1 | | | ___ _ __
calibre_1 | | | / __| | | / \
calibre_1 | | | \__ \ | | | () |
calibre_1 | |_| |___/ |_| \__/
calibre_1 | Brought to you by linuxserver.io
calibre_1 | -------------------------------------
calibre_1 | To support LSIO projects visit:
calibre_1 | https://www.linuxserver.io/donate/
@danielwagn3r
danielwagn3r / README.md
Last active March 11, 2021 08:08
Scoop App manifests

hcloud: Command-line interface for Hetzner Cloud

Prerequisites

Installation

scoop install https://gist.githubusercontent.com/danielwagn3r/46d5781676d0660c1c31d301df199b50/raw/70645b8e1979c35d3a56c8b4edd9ebec18429d0c/hcloud.json
### Keybase proof
I hereby claim:
* I am danielwagn3r on github.
* I am danielwagner (https://keybase.io/danielwagner) on keybase.
* I have a public key whose fingerprint is 3BD6 7912 21E8 B86E CC13 50C2 C4AE 96AF 86E0 D426
To claim this, I am signing this object:
@danielwagn3r
danielwagn3r / overflow.c
Created December 2, 2017 20:00
Overflow Check in C
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
int main()
{
}
if ((b > 0 && a <= INT_MAX / b && a >= INT_MIN / b) ||