Skip to content

Instantly share code, notes, and snippets.

@rahularity
rahularity / work-with-multiple-github-accounts.md
Last active April 24, 2025 08:37
How To Work With Multiple Github Accounts on your PC

How To Work With Multiple Github Accounts on a single Machine

Let suppose I have two github accounts, https://github.com/rahul-office and https://github.com/rahul-personal. Now i want to setup my mac to easily talk to both the github accounts.

NOTE: This logic can be extended to more than two accounts also. :)

The setup can be done in 5 easy steps:

Steps:

  • Step 1 : Create SSH keys for all accounts
  • Step 2 : Add SSH keys to SSH Agent
@n1snt
n1snt / Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md
Last active April 24, 2025 08:28
Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

@ipenywis
ipenywis / cursor-memory-bank-rules.md
Last active April 24, 2025 08:31
Cursor Memory Bank

Cursor's Memory Bank

I am Cursor, an expert software engineer with a unique characteristic: my memory resets completely between sessions. This isn't a limitation - it's what drives me to maintain perfect documentation. After each reset, I rely ENTIRELY on my Memory Bank to understand the project and continue work effectively. I MUST read ALL memory bank files at the start of EVERY task - this is not optional.

Memory Bank Structure

The Memory Bank consists of required core files and optional context files, all in Markdown format. Files build upon each other in a clear hierarchy:

flowchart TD
@sanatcodes
sanatcodes / gist:874d69b36f9a81aa1487b5770598ebdb
Last active April 24, 2025 08:25
Setup MongoDB replica set on local host with only a single primary - For Apple Silicon
Add the `replication` section to the mongod.conf file:
```
$cat /opt/homebrew/etc/mongod.conf
systemLog:
destination: file
path: /opt/homebrew/var/log/mongodb/mongo.log
logAppend: true
storage:
dbPath: /opt/homebrew/var/mongodb
@ChenyangGao
ChenyangGao / qrcode_cookie_115
Last active April 24, 2025 08:23
115扫码登录,可选择 app,获取 cookie
@MrPaXe
MrPaXe / JetBrainsTrial.bat
Last active April 24, 2025 08:13
Infinite Jetbrains Resharper trial
:: This bat file can be used to renew Resharper C# and Resharper C++ every time it runs out
:: It most likely works for all Jetbrains tools, however, I did not test this.
:: I was not able to find the original author for the reg key and the folders that needs to be deleted so if that is you feel free to reach out for credit
@echo off
setlocal enableDelayedExpansion
:confirm
echo Did you stop all Jetbrains services?
echo Jetbrains toolbox AND any other tool using it such as Rider, Visual Studio, ...
@bzvyagintsev
bzvyagintsev / README.md
Last active April 24, 2025 08:11
Шаблон README.md

Название проекта

Добавьте краткое описание проекта, опишите какую задачу он решает. 1-3 предложения будет достаточно. Добавьте бейджи для важных статусов проекта: статус разработки (в разработке, на поддержке и т.д.), статус билда, процент покрытия тестами и тд.

Содержание

@SwiftfulThinking
SwiftfulThinking / SignInWithGoogleHelper.swift
Last active April 24, 2025 07:27
Sign In With Google for iOS (async support)
//
//
//
//
//
//
// *****************************
// * THIS GIST HAS BEEN DEPRECATED. USE CODE HERE:
// https://github.com/SwiftfulThinking/SwiftfulFirebaseAuth/blob/main/Sources/SwiftfulFirebaseAuth/Helpers/SignInWithGoogle.swift
// *****************************
//fetch using a Request and a Headers objects
//using jsonplaceholder for the data
const uri = 'http://jsonplaceholder.typicode.com/users';
//new Request(uri)
//new Request(uri, options)
//options - method, headers, body, mode
//methods: GET, POST, PUT, DELETE, OPTIONS