Skip to content

Instantly share code, notes, and snippets.

@rolfn
rolfn / restic.md
Last active May 1, 2024 13:49
Backup auf Cloud-Speicher mit »restic«

Automatische Backups auf Online-Speicher mit »Restic«

Das Programm »Restic« ist ein modernes Backup-Programm, welches als Speicherort sowohl lokale Verzeichnisse als auch per Netzwerk erreichbare Speicher (Online-Speicher) nutzen kann. Der Autor von »Restic« zeigt in anschaulicher Weise in zwei Videos viele Details zur Arbeitsweise seines Programms: »FOSDEM 2015« (2015-01-28) und »CCCCologne« (2016-01-29).

Im Folgenden soll gezeigt werden, wie man unter Linux automatische Backups mit »Restic« einrichten kann. Als Speicherort wird per WebDAV-Protokoll erreichbarer Online-Speicher genutzt. Sinngemäß können die Hinweise aber auch auf andere Netzwerkprotokolle übertragen werden. Getestet wurde unter »openSUSE« und »Linux Mint« (»Ubuntu«), wobei aber auch alle anderen systemd-basierten Linux-Distributionen in derselben Art oder mit geringfügigen Änderungen geeignet sind.

Install

@johanneswilkens
johanneswilkens / neopixel-wwa.yaml
Created October 11, 2023 07:43
Control wwa sk6812 as cct bulb via esphome
esphome:
name: your-device-name
friendly_name: your-device-name
on_loop:
then:
if:
condition:
- light.is_on: WWAlight
then:
if:
<?php
use Automattic\WooCommerce\Blocks\Package;
/*
Plugin Name: Remove WooCommerce patterns
Version: 1.0.0
Plugin URI: https://mariecomet.fr/
Description: Remove all WooCommerce patterns
Author: Marie Comet
Author URI: https://mariecomet.fr/
<?php
/**
* Allow users to add an avatar at checkout for the Basic User Avatars plugin.
*
* This recipe assumes that you have the Basic User Avatar plugin installed and activated.
* @link https://wordpress.org/plugins/basic-user-avatars/
*
* This recipe requires a custom user field created with the name basic_user_avatar.
* The field should be set to "No" for the display on the profile option for either
* the group (Show fields on user profile?) or the field (Show field on user profile?).
@kimwhite
kimwhite / pmpromd-disable-oembed.php
Last active May 1, 2024 13:44 — forked from ipokkel/pmpromd-disable-oembed.php
Remove embeds on the PMPro Member Directory pages. #oembed
<?php
/**
* Remove embeds on the PMPro Member Directory pages.
*
* You can add this recipe to your site by creating a custom plugin
* or using the Code Snippets plugin available for free in the WordPress repository.
* Read this companion article for step-by-step directions on either method.
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/
*/
@kimwhite
kimwhite / my-pmpro-link-phone-on-directory-profile.php
Last active May 1, 2024 13:43
Display members phone number as a tel: link on your directory profile page.
@dwanjuki
dwanjuki / my_pmpromd_add_target_blank_to_url_fields.php
Last active May 1, 2024 13:43
Make website links on Member directory/profile pages open in new tab
<?php
/**
* Make user-submitted website links on Member directory/profile pages open in new tab
* Add names of fields with URLs to line 13
*
* You can add this recipe to your site by creating a custom plugin
* or using the Code Snippets plugin available for free in the WordPress repository.
* Read this companion article for step-by-step directions on either method.
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/
*/
@geohot
geohot / llm.c
Last active May 1, 2024 13:41
Outputted llm.c from tinygrad
#include <stdlib.h>
#include <stdbool.h>
#include <tgmath.h>
#define max(x,y) ((x>y)?x:y)
#define half __fp16
void E_(int* data0) {
int val0 = data0[0];
data0[0] = (val0+1);
}
@ryumada
ryumada / fix-missing-grub-after-windows-install-or-update.md
Last active May 1, 2024 13:41
How to fix missing grub from Boot Menu after windows install or update

How to fix missing grub from Boot Menu after windows install or update[^1]

Boot your computer using USB Bootable Linux

Burn Linux Live CD ISO into your USB drive. then boot to it.

Then, install grub-efi-amd or grub-efi-ia32 based on your system specification.

sudo apt install grub-efi-amd