Skip to content

Instantly share code, notes, and snippets.

@xals
xals / backupninja_borg
Created April 14, 2017 14:27
Borg backupninja config
# options = --force
# when = everyday at 02
[source]
type = local
keep = 30D
# A few notes about includes and excludes:
# 1. include, exclude and vsinclude statements support globbing with '*'
# 2. Symlinks are not dereferenced. Moreover, an include line whose path
@xals
xals / borg
Last active September 11, 2017 22:43 — forked from maethor/borg
BorgBackup handler script for backupninja
# -*- mode: sh; sh-basic-offset: 3; indent-tabs-mode: nil; -*-
# vim: set filetype=sh sw=3 sts=3 expandtab autoindent:
#
# borg handler script for backupninja
# requires borgbackup
#
# Guillaume Subiron, Sysnove, 2016
#
# Copyright 2016 Guillaume Subiron <[email protected]>
# This work is free. You can redistribute it and/or modify it under the
@xals
xals / README.txt
Last active June 28, 2018 12:40
Simple python3 program to send email from a Jinja2 template and a CSV datasource
This is a simple Python3 program, using a CSV file with headers as datasource. Column names are injected in the template rendering to be used as variable substitution.
This is not perfect. For example, the encoding fails for address headers when there are some accentuated characters (éèà for example) in the firsname or the lastname.
The template can contain UTF-8 characters, the message is Base64 encoded before beeing sent.

Keybase proof

I hereby claim:

  • I am xals on github.
  • I am xals (https://keybase.io/xals) on keybase.
  • I have a public key ASAzxFfawFvb5cy7XnCabQKsO3Yey2A924Np69JmTUR6bQo

To claim this, I am signing this object:

@xals
xals / fork.c
Last active August 29, 2015 14:01
My fork.
#define _XOPEN_SOURCE
#include<stdio.h>
#include<string.h>
#include<time.h>
#include<unistd.h>
// Main.
int main(int argc, char **argv) {
// Defining variables.