Skip to content

Instantly share code, notes, and snippets.

@bgauduch
bgauduch / multiple-repository-and-identities-git-configuration.md
Last active May 5, 2024 19:38
Git config with multiple identities and multiple repositories

Setup multiple git identities & git user informations

/!\ Be very carrefull in your setup : any misconfiguration make all the git config to fail silently ! Go trought this guide step by step and it should be fine 😉

Setup multiple git ssh identities for git

  • Generate your SSH keys as per your git provider documentation.
  • Add each public SSH keys to your git providers acounts.
  • In your ~/.ssh/config, set each ssh key for each repository as in this exemple:
@subfuzion
subfuzion / global-gitignore.md
Last active May 5, 2024 19:34
Global gitignore

There are certain files created by particular editors, IDEs, operating systems, etc., that do not belong in a repository. But adding system-specific files to the repo's .gitignore is considered a poor practice. This file should only exclude files and directories that are a part of the package that should not be versioned (such as the node_modules directory) as well as files that are generated (and regenerated) as artifacts of a build process.

All other files should be in your own global gitignore file:

  • Create a file called .gitignore in your home directory and add any filepath patterns you want to ignore.
  • Tell git where your global gitignore file is.

Note: The specific name and path you choose aren't important as long as you configure git to find it, as shown below. You could substitute .config/git/ignore for .gitignore in your home directory, if you prefer.

@Vertecedoc4545
Vertecedoc4545 / Hyprland-Ubuntu.md
Last active May 5, 2024 19:33
Ubuntu 23.04 Build and Install instructions for Hyprland

Building on Ubuntu 23.04

You have 2 options, use the script descrived bellow or follow the instrutions

script in this gist if you want the source code

wget https://gist.githubusercontent.com/Vertecedoc4545/6e54487f07a1888b656b656c0cdd9764/raw/2c5e8ccb428fc331307e2f653cab88174c051310/build-ubuntu-23.sh
chmod +x build-ubuntu-23.sh
./build-ubuntu-23.sh
@jerodg
jerodg / windows_and_office_kms_setup.adoc
Last active May 5, 2024 19:33
Activate Windows and Office Using KMS Server

Microsoft Windows and Office KMS Setup

@ShipkaChalk
ShipkaChalk / gist:629fdc42dad781776d2007fc502188f3
Last active May 5, 2024 19:33
Plex Hetzner workaround using Docker.

Hey, here is how you can route all plex traffic via wireguard out of another VPS, this can be used for any container but was inspired by the recent Hetzner block Plex put in place.

And no not all of us are using it for nefarious means, sometimes people don't have room for a home server.

Why docker? I prefer it as it keeps items separated and cleaned. It also allows for quickly moving configurations around from server to server if need be.

  1. Get yourself a VPS
  2. Install docker
  3. Create this docker-compose.yml
@rahularity
rahularity / work-with-multiple-github-accounts.md
Last active May 5, 2024 19:32
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
@caorong
caorong / resilio_sync_v2ray.md
Created November 21, 2019 15:45 — forked from wangyan/resilio_sync_v2ray.md
Resilio Sync 科学之路

“没有可用的跟踪程序连接”,现在 Resilio Sync 已经不可用了,原因是官方的 Tracker 服务器被和谐了。一个普遍方法是,通过 Zerotier 构建虚拟局域网来跳过 Tracker 服务器,甚至将 sync 降级到 1.4.111 版本来加入 DHT 网络,但最后的实际体验都非常不友好,所以科学连上 Tracker 服务器才是正道。

一、原因

Sync 启动后会从 https://config.resilio.com/sync.conf 或者 http://config.getsync.com/sync.conf 获取 trackers 和 relays 服务器列表,而这两个地址均已被屏蔽。

sync.conf 文件内容如下:

sync.conf

@fnky
fnky / ANSI.md
Last active May 5, 2024 19:31
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@fnky
fnky / stripe-keys-and-ids.tsv
Last active May 5, 2024 19:31
Stripe keys and IDs
Prefix Description Notes
ac_ Platform Client ID Identifier for an auth code/client id.
acct_ Account ID Identifier for an Account object.
aliacc_ Alipay Account ID Identifier for an Alipay account.
ba_ Bank Account ID Identifier for a Bank Account object.
btok_ Bank Token ID Identifier for a Bank Token object.
card_ Card ID Identifier for a Card object.
cbtxn_ Customer Balance Transaction ID Identifier for a Customer Balance Transaction object.
ch_ Charge ID Identifier for a Charge object.
cn_ Credit Note ID Identifier for a Credit Note object.
@dustinknopoff
dustinknopoff / README.md
Last active May 5, 2024 19:30
Automatically Save emails to a folder using Mail.app, AppleScript, and Bash.

How to get it to work.

NOTE: This is mac only.

  1. Go to Finder.
  2. Press CMD+SHIFT+G.
  3. Type ~/Library/Application Scripts/com.apple.mail.
  4. Open saveByRule.scpt and change theFolder to where you'd like emails to be saved.
  5. Copy and Paste saveByRule.scpt into ~/Library/Application Scripts/com.apple.mail.
  6. Go to Mail>Preferences>Rules>Add Rule.