Skip to content

Instantly share code, notes, and snippets.

View dtarczynski's full-sized avatar

Dariusz Tarczyński dtarczynski

View GitHub Profile
create rule protect_on_delete as
on delete to lm."TestTable"
where old."Id" > 0
do instead nothing;
@dtarczynski
dtarczynski / k9s_install.sh
Last active December 15, 2023 16:43
Install k9s on WSL
curl -s -L https://github.com/derailed/k9s/releases/download/v0.26.0/k9s_Linux_x86_64.tar.gz -o k9s && tar -xvf k9s && chmod 755 k9s && rm LICENSE README.md && sudo mv k9s /usr/local/bin
@dtarczynski
dtarczynski / DailyUbuntu.md
Last active December 8, 2021 12:19
DailyUbuntu

Ctrl Alt T New Terminal

Ctrl L Clear Terminal

Sh Win Arrow Move window to the next screen

0x5310D3587CE30F017E1A328880D8554F591731BE952129E7902CC155D2AE505A

Daily commands

Auto set remote for push

git config --global --add push.default current

git config --global --add push.autoSetupRemote true

Fetch from origin

git fetch origin

@dtarczynski
dtarczynski / Test.cs
Created May 28, 2020 21:29
BenchTest
public class Md5VsSha256
{
private SHA256 sha256 = SHA256.Create();
private MD5 md5 = MD5.Create();
private byte[] data;
[Params(1000, 10000)]
public int N;
[GlobalSetup]
using System;
using Newtonsoft.Json;
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)
{
Event[] events = new Event[2];
{
"events":[
{
"id":"1562272206591725",
"order":{
"seller":{
"id":"43942144"
},
"buyer":{
"id":"43955557",
@dtarczynski
dtarczynski / vpn.md
Created March 1, 2018 11:33 — forked from joepie91/vpn.md
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

(A Russian translation of this article can be found here, contributed by Timur Demin.)

Why not?