Skip to content

Instantly share code, notes, and snippets.

@noamtamim
noamtamim / README.md
Last active March 29, 2024 11:36
Markdown with PlantUML

How to use PlantUML with Markdown

PlantUML is a really awesome way to create diagrams by writing code instead of drawing and dragging visual elements. Markdown is a really nice documentation tool.

Here's how I combine the two, to create docs with embedded diagrams.

Step 0: Setup

Get the command-line PlantUML from the download page or your relevant package manager.

@sxiii
sxiii / p2p-vpns.md
Created September 10, 2021 07:13
P2P VPN List

An guide how to activate Windows 11 Pro for free

Why?

Because you will get some more features like an Bitlocker and host your device as an External Desktop which can be accessed through the internet

Am i also able to switch from any other edition to Pro?

The answer is yes! You can switch from almost any edition to Pro completely for free!

Note for users with unactivated Pro edition

People which already have Pro, but not activated, can skip to this step.

Getting started

What you first need to do is open CMD (Command Prompt) as Administrator using this keyboard key:

@Namburger
Namburger / tflite_cv_objdetect.py
Last active March 29, 2024 11:31
An example with opencv/tflite object detection combo
import os
import argparse
import cv2
import numpy as np
import sys
import time
import importlib.util
from tflite_runtime.interpreter import Interpreter
from tflite_runtime.interpreter import load_delegate
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active March 29, 2024 11:29
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

type Uuid = string;
@metaskills
metaskills / gist:893599
Created March 29, 2011 23:54
A Copy Of sp_MSforeachtable Stored Procedure For Azure, Uses sp_MSforeach_worker
CREATE proc [dbo].[sp_MSforeachtable]
@command1 nvarchar(2000), @replacechar nchar(1) = N'?', @command2 nvarchar(2000) = null,
@command3 nvarchar(2000) = null, @whereand nvarchar(2000) = null,
@precommand nvarchar(2000) = null, @postcommand nvarchar(2000) = null
AS
declare @mscat nvarchar(12)
select @mscat = ltrim(str(convert(int, 0x0002)))
if (@precommand is not null)
exec(@precommand)
@unitycoder
unitycoder / if-branchless.shader
Last active March 29, 2024 11:27
Avoiding Branching / Conditionals in Shaders Fast No If
"The common wisdom of "don't use conditionals in shaders" is one of my biggest frustrations with how shaders are taught.
step(y, x) _is_ a conditional! It compiles to identical code as:
float val = (x >= y ? 1.0 : 0.0)
or
float val = 0.0;
if (x >= y) val = 1.0;"
https://twitter.com/bgolus/status/1235254923819802626
// Performing shader divisions without diving *rcp = approximation of 1/x
float myDividedVal = myValToDivide * rcp(myDivider);