Skip to content

Instantly share code, notes, and snippets.

Avatar

Grégoire MOLVEAU gmolveau

View GitHub Profile
@gmolveau
gmolveau / checklist_demenagement.md
Created Jan 22, 2023
Checklist déménagement (VINCI)
View checklist_demenagement.md
@gmolveau
gmolveau / bg.jpg
Last active Dec 19, 2022
a dark black plain background
@gmolveau
gmolveau / freeze-camera.md
Created Nov 24, 2022
zoom / teams / skype - fake camera freeze recording
View freeze-camera.md
  • download and install OBS
  • record videos via webcam (Photobooth on macOS for example)
  • in OBS :
    • create 2 scenes : Real and Fake
    • in the real scene, add the real webcam
    • in the fake scene, add a media source, choose the video recording, select "on loop"
    • click on the real scene to select it
    • click on Start Virtual Camera
  • when u need to switch to a real scene, simply select the real scene
@gmolveau
gmolveau / exercice_numerotation_text.py
Last active Oct 25, 2022
exercice_numerotation_text.py
View exercice_numerotation_text.py
text_input = """a
b
c
d
e
f
"""
text_output = """1. a
1.1. b
@gmolveau
gmolveau / shrug.sh
Created Oct 11, 2022
shrug emoji bash alias
View shrug.sh
alias shrug='echo -E "¯\_(ツ)_/¯" | tee /dev/tty | pbcopy'
@gmolveau
gmolveau / 1.srp.py
Created Sep 11, 2022 — forked from dmmeteo/1.srp.py
SOLID Principles explained in Python with examples.
View 1.srp.py
"""
Single Responsibility Principle
“…You had one job” — Loki to Skurge in Thor: Ragnarok
A class should have only one job.
If a class has more than one responsibility, it becomes coupled.
A change to one responsibility results to modification of the other responsibility.
"""
class Animal:
def __init__(self, name: str):
@gmolveau
gmolveau / .Xmodmap
Created Sep 8, 2022
linux/ubuntu disable next/previous mouse clicks/buttons
View .Xmodmap
# ~/.Xmodmap
# disable next/previous mouse clicks
pointer = 1 2 3 4 5 6 7 0 0
@gmolveau
gmolveau / mount_lvm_usb.sh
Last active Aug 23, 2022
linux/lvm mount external USB LVM partition
View mount_lvm_usb.sh
sudo vgscan
# note vg name
sudo vgchange -ay <VG-NAME>
sudo lvdisplay
# note `LV Path`
sudo mkdir -p /media/usb/lvm_usb
sudo mount <LV-PATH> /media/usb/lvm_usb
# to automount this partition
sudo nano /etc/fstab
@gmolveau
gmolveau / fix-vgname.sh
Created Aug 23, 2022
linux/lvm fix duplicate vg names with vgrename uuid
View fix-vgname.sh
sudo vgdisplay
# note UUID
sudo vgrename <UUID> <new-vg-name>
# done.
@gmolveau
gmolveau / spotlight_index_reset.sh
Created Aug 23, 2022
macos spotlight index reset
View spotlight_index_reset.sh
sudo mdutil -Ea
sudo mdutil -ai off
sudo mdutil -ai on