Skip to content

Instantly share code, notes, and snippets.

@dmrub
dmrub / Dockerfile
Last active May 8, 2024 17:07
Dockerfile piece for installing su-exec in debian/ubuntu container
# Install latest su-exec
RUN set -ex; \
\
curl -o /usr/local/bin/su-exec.c https://raw.githubusercontent.com/ncopa/su-exec/master/su-exec.c; \
\
fetch_deps='gcc libc-dev'; \
apt-get update; \
apt-get install -y --no-install-recommends $fetch_deps; \
rm -rf /var/lib/apt/lists/*; \
gcc -Wall \
@Klerith
Klerith / pasos-node-typescript.md
Last active May 8, 2024 17:06
Configurar proyecto de Node con TypeScript

Pasos para usar Node con TypeScript con Nodemon

Más información - Docs Oficiales

  1. Instalar TypeScript y tipos de Node, como dependencia de desarrollo
npm i -D typescript @types/node
  1. Inicializar el archivo de configuración de TypeScript ( Se puede configurar al gusto)
@yajra
yajra / PHPExcel_Basics.md
Created January 20, 2016 01:52 — forked from r-sal/PHPExcel_Basics.md
PHPExcel Notes and code snippets

Basics

Creating a new PHPExcel Object.

    $this->PHPExcel = new PHPExcel();

Working with sheets

Creating a new sheet:

@saiashirwad
saiashirwad / Dark-Reader-Settings.json
Created September 25, 2020 00:23
Dark Reader Chrome Settings Gruvbox
{
"applyToListedOnly": false,
"automation": "",
"changeBrowserTheme": false,
"customThemes": [
{
"url": [
"arxiv.org"
],
"theme": {
@CarloNicolini
CarloNicolini / ralign
Created October 23, 2013 12:47
Umeyama algorithm for absolute orientation problem in Python
"""
RALIGN - Rigid alignment of two sets of points in k-dimensional
Euclidean space. Given two sets of points in
correspondence, this function computes the scaling,
rotation, and translation that define the transform TR
that minimizes the sum of squared errors between TR(X)
and its corresponding points in Y. This routine takes
O(n k^3)-time.
Inputs:
@Lewiscowles1986
Lewiscowles1986 / extract_har.py
Last active May 8, 2024 17:00 — forked from kafran/extract_har.py
Python 3 script to extract images from HTTP Archive (HAR) files
import json
import base64
import os
import pathlib
from urllib.parse import urlparse
# list of supported image mime-types
# Special thanks to https://gist.github.com/FurloSK/0477e01024f701db42341fc3223a5d8c
# Special mention, and thanks to MDN
# https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types
@P7h
P7h / tmux_vs_screen.md
Last active May 8, 2024 17:00
tmux vs screen commands

tmux vs. screen commands


Action tmux screen
start a new session tmux
tmux new
tmux new-session
screen
start a new session with a name tmux new -s name screen -S name
re-attach a detached session tmux attach
tmux attach-session
screen -r
re-attach a detached session with a name tmux attach -t name
tmux a -t name
screen -r name
re-attach an attached session (detaching it from elsewhere) tmux attach -dtmux attach-session -d screen -dr
@pickx
pickx / pylance_patcher.rs
Last active May 8, 2024 16:56
Patch Pylance's VSCode check
#!/usr/bin/env -S cargo +nightly -Zscript --quiet
---
[package]
edition = "2021"
[dependencies]
eyre = "0.6.12"
home = "0.5.9"
---
@muff-in
muff-in / resources.md
Last active May 8, 2024 16:56
A curated list of Assembly Language / Reversing / Malware Analysis / Game Hacking-resources
@mbostock
mbostock / .block
Last active May 8, 2024 16:54 — forked from mbostock/.block
Choropleth
license: gpl-3.0
height: 600
border: no
redirect: https://beta.observablehq.com/@mbostock/d3-choropleth