Skip to content

Instantly share code, notes, and snippets.

@schacon
schacon / better-git-branch.sh
Created January 13, 2024 18:41
Better Git Branch output
#!/bin/bash
# Colors
RED='\033[0;31m'
GREEN='\033[0;32m'
NO_COLOR='\033[0m'
BLUE='\033[0;34m'
YELLOW='\033[0;33m'
NO_COLOR='\033[0m'
@JJGO
JJGO / dstest
Last active December 4, 2024 06:46
Utility for running MIT 6.824 lab test in parallel and saving failed logs
#!/usr/bin/env python
import itertools
import math
import signal
import subprocess
import tempfile
import shutil
import time
import os
@ConnerWill
ConnerWill / ANSI-escape-sequences.md
Last active December 4, 2024 06:44
ANSI Escape Sequences cheatsheet

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@jordan-brough
jordan-brough / git-recent
Last active December 4, 2024 06:39
Git: Display a list of recently checked out branches/tags/commits
#!/usr/bin/env bash
# Source: https://gist.github.com/jordan-brough/48e2803c0ffa6dc2e0bd
# See also: https://stackoverflow.com/a/25095062/58876
# Download this script as "git-recent" (no extension), chmod it to be executable and put it in your
# path somewhere (e.g. /usr/bin). You can then use it via `git recent` from inside any git repo.
# Examples:
@zmts
zmts / tokens.md
Last active December 4, 2024 06:34
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Last major update: 25.08.2020

  • Что такое авторизация/аутентификация
  • Где хранить токены
  • Как ставить куки ?
  • Процесс логина
  • Процесс рефреш токенов
  • Кража токенов/Механизм контроля токенов
@kyo-takano
kyo-takano / making-the-most-of-local-llms.ipynb
Last active December 4, 2024 06:33
ローカルLLMはこーやって使うの💢
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@liuran001
liuran001 / config.yaml
Last active December 4, 2024 06:32
mihomo (Clash Meta) 懒人配置
# mihomo (Clash Meta) 懒人配置
# 版本 V1.12-241024
# https://gist.github.com/liuran001/5ca84f7def53c70b554d3f765ff86a33
# https://obdo.cc/meta
# 作者: 笨蛋ovo (bdovo.cc)
# Telegram: https://t.me/baka_not_baka
# 关注我的 Telegram 频道谢谢喵 https://t.me/s/BDovo_Channel
# 修改自官方示例规则 https://wiki.metacubex.one/example/#meta
# 转载请保留此注释
# 尽量添加了较为详尽的注释,不理解的地方建议对照 虚空终端 (Clash Meta) Docs 进行理解
@lesterlo
lesterlo / apple_hidpi_list.md
Last active December 4, 2024 06:27
Apple display HiDPI resolution list

Below table listed the HiDPI resolution on all apple device.

Mac Display Type Air/Pro 13" (Intel) Air/Pro 13" (M1) Pro 16" iMac 21.5" iMac 27" Pro Display XDR
Monitor Size 13 inch 13 inch 16 inch 21.5 inch 27 inch 32 inch
Native Resolution 2560 x 1600 2560 x 1600 3072 x 1920 4096 × 2304 5120 x 2880 6016 x 3384
HiDPI Level 1 1024 x 640 1024 x 640 1152 x 720 1280 x 720 * 1600 x 900 * 1504 x 846 *
HiDPI Level 2 1280 x 800 1280 x 800 1344 x 840 1680 x 945 * 2048 x 1152 * 1920 x 1080 *
HiDPI Level 3 1440 x 900 1440 x 900 1536 x 960 2048 x 1152 2560 x 1440 2560 x 1440 *
HiDPI Level 4 1680 x 1050 1680 x 1050 1792 x 112
@pablotolentino
pablotolentino / Visual Studio 2022 Product Key
Created November 20, 2021 20:41
Visual Studio 2022 Enterprise Product key
Visual Studio 2022
Enterprise :
VHF9H-NXBBB-638P6-6JHCY-88JWH
Professional:
TD244-P4NB7-YQ6XK-Y8MMM-YWV2J