Skip to content

Instantly share code, notes, and snippets.

@pratyakshm
pratyakshm / windowsinstallusingdism.md
Last active May 11, 2024 04:23
Installing Windows 11 on any device using DISM

Install Windows 11 on unsupported devices

Guide to install Windows 11 on any PC (does not involve ISO modifications) This guide will take you through a clean and simple way to install Windows 11 on your device by bypassing all requirements without doing any ISO modifications. Note: Guide shows fresh installation only.

Requirements:

  1. ISO file (Link 1) (Link 2) (22000.65)
  2. Rufus Microsoft Store GitHub Website
  3. USB drive [8GB or more]
@mrkline
mrkline / c_sharp_for_python.md
Last active May 11, 2024 04:20
An intro to C# for a Python developer. Made for one of my coworkers.

C# For Python Programmers

Syntax and core concepts

Basic Syntax

  • Single-line comments are started with //. Multi-line comments are started with /* and ended with */.

  • C# uses braces ({ and }) instead of indentation to organize code into blocks. If a block is a single line, the braces can be omitted. For example,

@AveYo
AveYo / 7-Zip_Windows11.reg
Last active May 11, 2024 04:20
7-Zip Windows 11 Context Menu entries via whitelisted id reuse example by AveYo
Windows Registry Editor Version 5.00
; 7-Zip Windows 11 Context Menu entries via whitelisted id reuse example by AveYo
; Add to archive.. only single files (multiple would need a single instance redirect tool)
[-HKEY_CURRENT_USER\SOFTWARE\Classes\*\shell\connectNetworkDrive]
[HKEY_CURRENT_USER\SOFTWARE\Classes\*\shell\connectNetworkDrive]
"MuiVerb"="@C:\\Program Files\\7-Zip\\7-zip.dll,-2324"
"Position"="Middle"
"Icon"="C:\\Program Files\\7-Zip\\7-zip.dll,0"
@david082321
david082321 / tw.sh
Last active May 11, 2024 04:19 — forked from XargonWan/japanese_locale_enabler.sh
Steam Deck 中文化
#!/bin/bash
# 停用 唯讀模式
sudo steamos-readonly disable
# 初始化 Pacman Keys
sudo pacman-key --init
sudo pacman-key --populate archlinux
# 重新安裝 glibc
sudo pacman -S glibc --noconfirm
# 編輯 locale.gen
sudo sed -i "s%#zh_TW.UTF-8 UTF-8%zh_TW.UTF-8 UTF-8%" /etc/locale.gen
@theodorosploumis
theodorosploumis / Nework_throttling_profiles.md
Last active May 11, 2024 04:18
Web development - Custom network throttling profiles
Profile download (kb/s) upload (kb/s) latency (ms)
Native 0 0 0
GPRS 50 20 500
56K Dial-up 50 30 120
Mobile EDGE 240 200 840
2G Regular 250 50 300
2G Good 450 150 150
3G Slow 780 330 200
@wojteklu
wojteklu / clean_code.md
Last active May 11, 2024 04:18
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@JamieMason
JamieMason / unfollow.js.md
Last active May 11, 2024 04:17
Unfollow everyone on twitter.com

Unfollow everyone on twitter.com

  1. Go to https://twitter.com/YOUR_USER_NAME/following
  2. Open the Developer Console. (COMMAND+ALT+I on Mac)
  3. Paste this into the Developer Console and run it
// Unfollow everyone on twitter.com, by Jamie Mason (https://twitter.com/fold_left)
// https://gist.github.com/JamieMason/7580315
//
@baleyko
baleyko / socat_server.sh
Created March 8, 2018 10:44 — forked from CMCDragonkai/socat_server.sh
Socat: Simple HTTP Server
socat \
-v -d -d \
TCP-LISTEN:1234,crlf,reuseaddr,fork \
SYSTEM:"
echo HTTP/1.1 200 OK;
echo Content-Type\: text/plain;
echo;
echo \"Server: \$SOCAT_SOCKADDR:\$SOCAT_SOCKPORT\";
echo \"Client: \$SOCAT_PEERADDR:\$SOCAT_PEERPORT\";
"
@mrcunninghamz
mrcunninghamz / SelfSignedCert.md
Last active May 11, 2024 04:17
Creating a self signed certificate in a pfx format on a mac.

Create Self Signed Certificate using OpenSSL on a Mac

Introduction

Every now and then I need to create a self signed certificate in azure for something. In my particular case its Azure B2C. I am using a mac so its not simply just running something like

New-SelfSignedCertificate `
    -KeyExportPolicy Exportable `
    -Subject "CN=yourappname.yourtenant.onmicrosoft.com" `
 -KeyAlgorithm RSA `
@jboner
jboner / latency.txt
Last active May 11, 2024 04:16
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
----------------------------------
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD