Skip to content

Instantly share code, notes, and snippets.

View YannBirba's full-sized avatar
⚛️
React ♥️

Yann YannBirba

⚛️
React ♥️
View GitHub Profile
@YannBirba
YannBirba / borgmatic.service
Created January 9, 2024 13:51
Borgmatic service timer configuration file at /lib/systemd/system/borgmatic.service
[Unit]
Description=borgmatic backup
Wants=network-online.target
After=network-online.target
# Prevent borgmatic from running unless the machine is plugged into power. Remove this line if you
# want to allow borgmatic to run anytime.
ConditionACPower=true
ConditionFileNotEmpty=/etc/borgmatic/config.yaml
Documentation=https://torsion.org/borgmatic/
@YannBirba
YannBirba / borgmatic.timer
Created January 9, 2024 13:36
Borgmatic service timer configuration file at /lib/systemd/system/borgmatic.timer
[Unit]
Description=Run borgmatic backup every day at 4:00:00
[Timer]
OnCalendar=*-*-* 4:00:00
Persistent=true
[Install]
WantedBy=timers.target
@YannBirba
YannBirba / config.yaml
Last active January 9, 2024 13:57
Borgmatic config file /etc/borgmatic/config.yaml
# Where to look for files to backup, and where to store those backups.
# See https://borgbackup.readthedocs.io/en/stable/quickstart.html and
# https://borgbackup.readthedocs.io/en/stable/usage/create.html
# for details.
location:
# List of source directories to backup (required). Globs and
# tildes are expanded. Do not backslash spaces in path names.
source_directories:
- /home/######
@YannBirba
YannBirba / startup
Last active January 15, 2024 18:36
Start all docker containers in specific dir
#! /bin/bash
###
# Created date: 17/12/2023
# Created by: Yann Birba
# Description: Script to start docker containers
###
# Variables
@YannBirba
YannBirba / settings.json
Created June 9, 2023 18:12
VS code default settings.json
{
"liveServer.settings.donotVerifyTags": true,
"editor.minimap.enabled": false,
"editor.autoClosingBrackets": "always",
"editor.autoClosingOvertype": "always",
"editor.autoClosingQuotes": "always",
"workbench.iconTheme": "material-icon-theme",
"liveServer.settings.CustomBrowser": "chrome",
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
{"name":"VS code pro profile","settings":"{\"settings\":\"{\\r\\n \\\"liveServer.settings.donotVerifyTags\\\": true,\\r\\n \\\"editor.minimap.enabled\\\": false,\\r\\n \\\"editor.autoClosingBrackets\\\": \\\"always\\\",\\r\\n \\\"editor.autoClosingOvertype\\\": \\\"always\\\",\\r\\n \\\"editor.autoClosingQuotes\\\": \\\"always\\\",\\r\\n \\\"workbench.iconTheme\\\": \\\"material-icon-theme\\\",\\r\\n \\\"liveServer.settings.CustomBrowser\\\": \\\"chrome\\\",\\r\\n \\\"[javascript]\\\": {\\r\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\r\\n },\\r\\n \\\"oneDarkPro.vivid\\\": true,\\r\\n \\\"oneDarkPro.bold\\\": true,\\r\\n \\\"workbench.colorTheme\\\": \\\"One Dark Pro\\\",\\r\\n \\\"terminal.integrated.defaultProfile.windows\\\": \\\"Ubuntu (WSL)\\\",\\r\\n \\\"editor.wordWrap\\\": \\\"on\\\",\\r\\n \\\"editor.codeLensFontFamily\\\": \\\"JetBrainsMono Nerd Font, JetBrains Mono, Consolas, 'Courier New', monospace\\\",\\r\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.p
{"name":"VS Code perso profile","settings":"{\"settings\":\"{\\r\\n \\\"liveServer.settings.donotVerifyTags\\\": true,\\r\\n \\\"editor.minimap.enabled\\\": false,\\r\\n \\\"editor.autoClosingBrackets\\\": \\\"always\\\",\\r\\n \\\"editor.autoClosingOvertype\\\": \\\"always\\\",\\r\\n \\\"editor.autoClosingQuotes\\\": \\\"always\\\",\\r\\n \\\"workbench.iconTheme\\\": \\\"material-icon-theme\\\",\\r\\n \\\"liveServer.settings.CustomBrowser\\\": \\\"chrome\\\",\\r\\n \\\"[javascript]\\\": {\\r\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\r\\n },\\r\\n \\\"oneDarkPro.vivid\\\": true,\\r\\n \\\"oneDarkPro.bold\\\": true,\\r\\n \\\"workbench.colorTheme\\\": \\\"One Dark Pro\\\",\\r\\n \\\"terminal.integrated.defaultProfile.windows\\\": \\\"Ubuntu (WSL)\\\",\\r\\n \\\"editor.wordWrap\\\": \\\"on\\\",\\r\\n \\\"editor.codeLensFontFamily\\\": \\\"JetBrainsMono Nerd Font, JetBrains Mono, Consolas, 'Courier New', monospace\\\",\\r\\n \\\"editor.defaultFormatter\\\": \\\"esbenp
@YannBirba
YannBirba / reset.css
Created April 13, 2023 19:16
Modern css reset by Josh comeau
/*
Josh's Custom CSS Reset
https://www.joshwcomeau.com/css/custom-css-reset/
*/
*, *::before, *::after {
box-sizing: border-box;
}
* {
margin: 0;
}
This file has been truncated, but you can view the full file.
<!DOCTYPE html>
<html class="sl-root decks export loaded ua-phantomjs>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Présentation Rendering: Slides</title>
<meta name="description" content="Slides">
@YannBirba
YannBirba / challenge.ts
Created September 19, 2022 13:47
Quête typescript - Installation et types basiques
interface User {
name: string;
age: number;
birthday?: string;
}
const prettyPrintWilder = (users: User[]): void => {
users.map((user) => {
console.log(`${user.name} is ${user.age} years old`);
});