Skip to content

Instantly share code, notes, and snippets.

import { Module } from '@nestjs/common';
import { ServeStaticModule } from '@nestjs/serve-static';
import { AppController } from './app.controller';
import { AppService } from './app.service';
import { join } from 'path';
// we serve the static content from the html folder
https://fr.camelcamelcamel.com/ <- extension pour avoir l'historique des prix
https://keepa.com/ <- pareil pour historique
https://www.idealo.fr/ - <-comparateur de prix
https://www.dealabs.com/ <- site qui repertorie des deals
@bussiere
bussiere / one_flask.py
Created May 5, 2021 10:37 — forked from mikefromit/one_flask.py
a one file flask app for trying stuff
# THIS PROJECT IS AN EXAMPLE APP. SOME CODE MAY NOT BE ACTUALLY USEFUL
# FOR DEMONSTRATION PURPOSES ONLY
# YOUR MILEAGE MAY VARY
# Requirements are Flask, Flask-WTF, Flask-SQLAlchemy
import os
from flask import (Flask,
Blueprint,
redirect,
@bussiere
bussiere / autocomplete-group-results-trevoreyre-autocomplete-js.markdown
Created April 14, 2021 09:13
Autocomplete group results - @trevoreyre/autocomplete-js

Autocomplete group results - @trevoreyre/autocomplete-js

Example of an autocomplete component using a custom renderResult function to control of rendering of items in the results list, and grouping the results into groups of 3. Using the @trevoreyre/autocomplete-js package from npm.

A Pen by Trevor Eyre on CodePen.

License.

@bussiere
bussiere / srd_5e_monsters.json
Created January 14, 2021 21:44 — forked from tkfu/srd_5e_monsters.json
A JSON file with all the D&D 5e SRD monster data
[
{
"name": "Aboleth",
"meta": "Large aberration, lawful evil",
"Armor Class": "17 (Natural Armor)",
"Hit Points": "135 (18d10 + 36)",
"Speed": "10 ft., swim 40 ft. ",
"STR": "21",
"STR_mod": "(+5)",
"DEX": "9",
@bussiere
bussiere / config.go
Created December 18, 2020 20:49 — forked from chazcheadle/config.go
Golang Viper config read into struct
package main
import (
"fmt"
"github.com/spf13/viper"
)
// Create private data struct to hold config options.
type config struct {
@bussiere
bussiere / go-worker.go
Created February 16, 2020 19:58 — forked from System-Glitch/go-worker.go
A resilient service worker written in Go
package main
// This is an example of a resilient service worker program written in Go.
//
// This program will run a worker every 5 seconds and exit when SIGINT or SIGTERM
// is received, while ensuring any ongoing work is finished before exiting.
//
// Unexpected panics are also handled: program won't crash if the worker panics.
import (
@bussiere
bussiere / cantor_pairing.go
Created February 14, 2020 20:14 — forked from dyoo/cantor_pairing.go
Cantor pairing function
// http://en.wikipedia.org/wiki/Pairing_function
package main
import (
"fmt"
"math"
)
func InvertedCantorPairing(z int) (int, int) {
w := int(math.Floor((math.Sqrt(float64(8*z+1)) - 1) / 2))
@bussiere
bussiere / mtable
Created January 1, 2020 14:27
orm table map table in go
tables-to-go -v -t pg -h 127.0.0.1 -d dvfmicro -u user -p password
@bussiere
bussiere / Weirdest Harry Potter Fan Fic
Created December 23, 2019 21:49
Weirdest Harry Potter Fan Fic
You are Rubino, a rogue from the province of Elsbury. You have a pair of gloves
and a lockpick.
You go amongst the local vendors looking for some sperviter to rob. You decide
on one that is selling an elixir called "Sperminator". It seems like it would
be easy enough
> Buy the sperminator elixir
You buy the elixir and take it back to your hideout in the forest. You find out
you can't drink it, but you can use it as a lockpick