Skip to content

Instantly share code, notes, and snippets.

View mpoullet's full-sized avatar

Matthieu Poullet mpoullet

View GitHub Profile
@mpoullet
mpoullet / vm.sh
Created August 26, 2024 18:34 — forked from richardweinberger/vm.sh
Fastest QEMU VM setup
$ wget https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-nocloud-amd64.raw
$ qemu-system-x86_64 -M pc,accel=kvm -m 1G \
-drive file=./debian-12-nocloud-amd64.raw,if=virtio \
-netdev type=user,hostfwd=tcp::5573-:22,id=net0 \
-device virtio-net,netdev=net0 -rtc base=localtime -smp 4 \
-nographic
# login with user 'root'
VM$ apt update && apt install openssh-server
VM$ echo "PermitRootLogin yes" > /etc/ssh/sshd_config.d/root_login.conf
VM$ systemctl restart sshd
@mpoullet
mpoullet / nco.cpp
Created March 11, 2024 14:01 — forked from RickKimball/nco.cpp
NCO c++ template
// vim: set ts=2 sw=2 expandtab list
/*
* File: nco.cpp
* Description: NCO c++ template and testdriver
*
* Author: rick kimball
*
* g++ -DDEBUG -Wall -Os -g nco.cpp -o nco
*/
@mpoullet
mpoullet / Jenkinsfile
Created May 24, 2023 14:19 — forked from fabiojose/Jenkinsfile
Sample Jenkinsfile to build, test and deploy Platform-as-Code in Openshift
pipeline {
/* run in any agent (a.k.a. node executor) */
agent any
stages {
stage('Setup') {
steps {
script {
/* Check the GIT_BRANCH to compute the target environment */
if (env.GIT_BRANCH == 'origin/develop' || env.GIT_BRANCH ==~ /(.+)feature-(.+)/) {
@mpoullet
mpoullet / Makefile
Created October 27, 2022 20:47 — forked from prwhite/Makefile
Add a help target to a Makefile that will allow all targets to be self documenting
# Add the following 'help' target to your Makefile
# And add help text after each target name starting with '\#\#'
help: ## Show this help.
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'
# Everything below is an example
target00: ## This message will show up when typing 'make help'
@echo does nothing
@mpoullet
mpoullet / std.md
Created May 29, 2021 18:39 — forked from turbo/std.md
Git Commit Message Standard

Merged from https://github.com/joelparkerhenderson/git_commit_message and https://chris.beams.io/posts/git-commit/

General Rules

  • Commit messages must have a subject line and may have body copy. These must be separated by a blank line.
  • The subject line must not exceed 50 characters
  • The subject line should be capitalized and must not end in a period
  • The subject line must be written in imperative mood (Fix, not Fixed / Fixes etc.)
  • The body copy must be wrapped at 72 columns
  • The body copy must only contain explanations as to what and why, never how. The latter belongs in documentation and implementation.
@mpoullet
mpoullet / interactive_log_final.py
Created March 20, 2021 23:30 — forked from Seanny123/interactive_log_final.py
EE4208 Laplacian of Gaussian Edge Detector
import math
import numpy as np
import matplotlib.pyplot as plot
import matplotlib.cm as cm
import sys
import pylab
from matplotlib.widgets import Slider
range_inc = lambda start, end: range(start, end+1) #Because this is easier to write and read
@mpoullet
mpoullet / .gitignore
Created March 1, 2021 15:42 — forked from kogakure/.gitignore
Git: .gitignore file for LaTeX projects
*.aux
*.glo
*.idx
*.log
*.toc
*.ist
*.acn
*.acr
*.alg
*.bbl
@mpoullet
mpoullet / Makefile
Created January 29, 2021 21:37 — forked from geraldgong/Makefile
SHELL := /usr/bin/env bash
#######
# Help
#######
.DEFAULT_GOAL := help
.PHONY: help
help:
pipdeptree -f --warn silence | grep -v '[[:space:]]' > requirements.txt