Skip to content

Instantly share code, notes, and snippets.

# This xorg configuration file will start a dummy X11 server.
# move it to /etc/X11/xorg.conf
# don't forget apt install xserver-xorg-video-dummy;
# based on https://xpra.org/Xdummy.html
Section "ServerFlags"
Option "DontVTSwitch" "true"
Option "AllowMouseOpenFail" "true"
Option "PciForceNone" "true"
Option "AutoEnableDevices" "false"
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 3, 2024 18:53
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@JeffPaine
JeffPaine / i3-cheat-sheet.md
Last active May 3, 2024 18:44
i3 Window Manager Cheat Sheet

i3 Window Manager Cheat Sheet

$mod refers to the modifier key (alt by default)

General

  • startx i3 start i3 from command line
  • $mod+<Enter> open a terminal
  • $mod+d open dmenu (text based program launcher)
  • $mod+r resize mode ( or to leave resize mode)
  • $mod+shift+e exit i3
@bmaupin
bmaupin / free-database-hosting.md
Last active May 3, 2024 18:38
Free database hosting
@tejaskhot
tejaskhot / shapenet_synset_list
Created June 24, 2018 00:44
List of category names and their id in the ShapeNet dataset
04379243 table
03593526 jar
04225987 skateboard
02958343 car
02876657 bottle
04460130 tower
03001627 chair
02871439 bookshelf
02942699 camera
02691156 airplane
@davidalves1
davidalves1 / desfazendo-push.md
Last active May 3, 2024 18:38
Desfazendo um git push

Desfazendo um git push

Não é possível desfazer um push diretamente, como é feito com o commit utilizando o comando $ git reset --soft|mixed|hard hash-do-penultimo-commit

Para desfazer um push são necessários 3 passos:

  1. Utilizar o comando $ git reset --mixed HEAD~1 e em seguida utilizar o comando $ git stash (se preferir pode usar a opção -m "revertendo o push blablabla" para salvar o stash com um contexto do que foi feito
  2. Utilizar o comando $ git revert HEAD~0
  3. Utilizar o comando $ git stash apply
  4. Utilizar o comando $ git push origin sua-branch -f
@rphlmr
rphlmr / helpers.ts
Last active May 3, 2024 18:37
Drizzle ORM, deep sub queries
/* -------------------------------------------------------------------------- */
/* More here; */
/* -------------------------------------------------------------------------- */
//gist.github.com/rphlmr/0d1722a794ed5a16da0fdf6652902b15
https: export function distinctOn<Column extends AnyColumn>(column: Column) {
return sql<Column["_"]["data"]>`distinct on (${column}) ${column}`;
}
export function jsonBuildObject<T extends SelectedFields>(shape: T) {
@CHFR-wide
CHFR-wide / ease_copy_1.0.3.lua
Last active May 3, 2024 18:36
Script for saving and applying easing presets within davinci fusion
-- Easecopy v1.0.3
-- Changelog:
-- v1.0.3 : Makes the script composition-agnostic
-- v1.0.2 : Fixes an issue where number-only ease names would crash the script
----------------------
-- UI_MANAGER SETUP --
----------------------
@hfiref0x
hfiref0x / akagi_41.c
Created August 16, 2017 03:31
UAC bypass using CMSTPLUA COM interface
typedef interface ICMLuaUtil ICMLuaUtil;
typedef struct ICMLuaUtilVtbl {
BEGIN_INTERFACE
HRESULT(STDMETHODCALLTYPE *QueryInterface)(
__RPC__in ICMLuaUtil * This,
__RPC__in REFIID riid,
_COM_Outptr_ void **ppvObject);
@0xjac
0xjac / private_fork.md
Last active May 3, 2024 18:34
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare git@github.com:usi-systems/easytrace.git