Skip to content

Instantly share code, notes, and snippets.

View nclv's full-sized avatar
🖥️
Focusing

Nicolas Vincent nclv

🖥️
Focusing
View GitHub Profile
@nclv
nclv / warp.js
Created February 28, 2024 13:52 — forked from lzjluzijie/warp.js
Cloudflare Warp 24PB key generator
# See https://halu.lu/%E6%9D%82%E8%B0%88/cloudflare-warp/
# Depolyed at https://warp.halu.lu/
// Change keys if needed
const keys = [
"9WO41D5p-6OP8xj27-36gQG75D",
"R65K12Up-aU907O2e-4nuvD581",
"06LM94EJ-1nl0V2d7-V847va5y",
]
@nclv
nclv / System Design.md
Created February 27, 2024 09:03 — forked from vasanthk/System Design.md
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@nclv
nclv / utls.go
Last active January 5, 2023 10:27
package main
import (
"context"
"crypto/tls"
"fmt"
"io"
"net"
"strings"
@nclv
nclv / go-cpuprofile.go
Created June 13, 2021 09:29
Golang profiling with pprof
import "runtime/pprof"
func main() {
f, err := os.Create("cpuprofile")
if err != nil {
fmt.Fprintf(os.Stderr, "could not create CPU profile: %v\n", err)
os.Exit(1)
}
if err := pprof.StartCPUProfile(f); err != nil {
fmt.Fprintf(os.Stderr, "could not start CPU profile: %v\n", err)
@nclv
nclv / const.h
Created October 12, 2020 13:28
Module pour effectuer l'analyse temporelle de plusieurs fonctions avec des arguments différents
#ifndef _CONST_
#define _CONST_
#define n (1000)
#define m (1000)
#define RANGE (100)
typedef double E;
#endif
@nclv
nclv / dbg.h
Created August 31, 2020 07:51
From `Learn C the Hard Way`
#ifndef __dbg_h__
#define __dbg_h__
#include <stdio.h>
#include <errno.h>
#include <string.h>
#ifdef NDEBUG
#define debug(M, ...)
#else
@nclv
nclv / get_links.sh
Last active August 23, 2020 15:40
Récupère les liens des Weeknotes
#!/bin/bash
for file in links-ressources/*
do
sed -i "/<\!--stackedit_data:/,/-->/d" $file
done
@nclv
nclv / publish_weeknote.sh
Last active June 20, 2020 16:46
Publier et renommer les Weeknotes
#!/bin/bash
# publish_weeknote.sh
# L'objectif de ce programme est de transférer une weeknote sur le site.
# Il faut ajouter le header en format YAML.
# Changer le nom du fichier.
# Le copier dans le bon répertoire.
# Usage : ./publish_weeknotes.sh weeknote post_directory categories
# ./publish_weeknote.sh links-ressources/Weeknotes-09.md weeknotes/_posts/ markdown,algorithmique
#!/usr/bin/env bash
:"
VINCENT Nicolas
Création d'une architecture de projet dans le répertoire courant.
USAGE:
bash create_python_project.sh <project_name>