Skip to content

Instantly share code, notes, and snippets.

View nicolas-lutic's full-sized avatar

LUTIC NICOLAS nicolas-lutic

  • Loxodata
  • Nantes
  • 12:09 (UTC +02:00)
View GitHub Profile
@nicolas-lutic
nicolas-lutic / snippet_strava_change_bike_activities.md
Created August 8, 2025 13:37
Snippet massive change bike on strava

https://www.strava.com/athlete/training

document.querySelectorAll('#bike_id').forEach(element => (element.value = '5480647'))


document.querySelectorAll('.edit-col form .btn-sm').forEach(element => {
    element.click()
});
@nicolas-lutic
nicolas-lutic / fio_disk_benchmark.sh
Created June 23, 2025 12:12
fio disk vbenchmark
#!/bin/bash
# Répertoire temporaire de test
TEST_DIR="/data/testfio"
mkdir -p "$TEST_DIR"
# Taille du fichier de test (à adapter si besoin)
TEST_SIZE="4G"
# Durée des tests
RUNTIME=60
@nicolas-lutic
nicolas-lutic / oracle_fdw_debian.md
Created June 18, 2025 13:17
Install oracle_fwd on debian

Simply :

PG_VERSION=17
apt install postgresql-${PG_VERSION}-oracle-fdw
psql 
CREATE EXTENSION oracle_fdw ;
@nicolas-lutic
nicolas-lutic / pg_walinspect_sandbox.md
Created June 17, 2025 13:54
pg_walinspect playground !

Install Extension

  CREATE EXTENSION pg_walinspect ;
select start_lsn, end_lsn,  xid, resource_manager, record_type, record_length, description::varchar(50) from pg_get_wal_records_info('0/1C133C0', pg_current_wal_lsn());
┌───────────┬───────────┬─────┬──────────────────┬───────────────────┬───────────────┬────────────────────────────────────────────────────┐
│ start_lsn │  end_lsn  │ xid │ resource_manager │    record_type    │ record_length │                    description                     │
├───────────┼───────────┼─────┼──────────────────┼───────────────────┼───────────────┼────────────────────────────────────────────────────┤
│ 0/1C133C0 │ 0/1C133F8 │   0 │ Heap2            │ PRUNE_ON_ACCESS   │            52 │ , isCatalogRel: F, nplans: 0, nredirected: 0, ndea │
│ 0/1C133F8 │ 0/1C13430 │ 0 │ Standby │ RUNNING_XACTS │ 50 │ nextXid 754 latestCompletedXid 753 oldestRunningXi │
@nicolas-lutic
nicolas-lutic / keybase.md
Last active September 24, 2024 07:07
keybase.md

Keybase proof

I hereby claim:

  • I am nicolas-lutic on github.
  • I am nlu (https://keybase.io/nlu) on keybase.
  • I have a public key ASDrk-OUfaHOcCofZKgMxHvA_ZMrAFe0W_lmokiN_SXiHgo

To claim this, I am signing this object:

HELPS

alias dive="docker run -ti --rm  -v /var/run/docker.sock:/var/run/docker.sock docker.io/wagoodman/dive"

TOOLS

@nicolas-lutic
nicolas-lutic / obs-virtcam.md
Last active November 28, 2020 15:29
OBS + virtual CAM

Requirement :

sudo apt-get install v4l-utils v4l2loopback-dkms obs-v4l2sink
sudo modprobe v4l2loopback video_nr=10 devices=1 card_label="obs-cam" exclusive_caps=1
sudo modprobe v4l2loopback-dc video_nr=12 devices=1 card_label="droid-cam" exclusive_caps=1


cat /etc/modules-load.d/v4l2loopback.conf 
v4l2loopback
cat /etc/modprobe.d/v4l2loopback.conf 
sudo vim /etc/apt/sources.lis
deb http://ftp.debian.org/debian stretch-backports main
sudo apt-get install -t stretch-backports rsyslog-pgsql
@nicolas-lutic
nicolas-lutic / syncGitHubForkMaster.md
Last active April 19, 2018 13:12
Syncing my fork and the origin master
git clone git@github.com:nicolas-lutic/laravel.git

git remote add upstream git@github.com:laravel/laravel.git

git fetch upstream

git merge upstream/master

git push origin master
docker pull postgres
# create container
docker run --name test-db -e POSTGRES_PASSWORD=my_secret_password -d -p 5432:5432 postgres
# database test creation
docker run -it --rm --link test-db:postgres postgres psql -h postgres -U postgres -c "create database testdb"