Skip to content

Instantly share code, notes, and snippets.

@balajeerc
balajeerc / setup-deploy-key.sh
Created May 14, 2026 10:57
Create a per project deployment key for Github/Gitlab/Bitbucket
#!/usr/bin/env bash
# ============================================================
# setup-deploy-key.sh
#
# Generates a per-project SSH deploy key, wires it into ~/.ssh/config,
# prints the public key, waits for you to add it on the provider,
# then clones the repo into cwd using the aliased host so the new
# key is used.
#
# Supports GitHub, GitLab, and Bitbucket (cloud).
@balajeerc
balajeerc / mouse_free_howto.md
Last active February 27, 2025 15:06
Enabling Mousekeys on Linux: To Move Mouse with Numpad

Linux Mouse and Keyboard Tweaks

Enabling Mousekeys on Linux: To Move Mouse with Numpad

Why

You have a nice keyboard. And using the mouse hinders your workflow.

Installation

sudo aptitude install xkbset
@balajeerc
balajeerc / git_cheatsheet.md
Last active October 5, 2018 06:51
My Git Cheatsheet

My Git Cheatsheet

Show a diff of the last change made in a file in any commit

git log -p -n 1 <filename>

Show changes since last commit

@balajeerc
balajeerc / bash_snippets.md
Last active September 23, 2025 05:19
Bash Snippets

Bash Snippets

DNS Issue Debugging

Have you tried turning it off and on again? :)

sudo systemctl restart NetworkManager
sudo ip route flush cache
@balajeerc
balajeerc / copy_yum_repo.js
Last active January 3, 2016 18:08
Nodejs script that copies files of a specified yum package along with those of its dependencies (queried recursively) into a folder
#!/bin/sh
':' //; exec "$(command -v nodejs || command -v node)" "$0" "$@"
"use strict";
/*
* Copies over the files from an installed yum package into a specified folder
* along with the files of all its dependency packages
*
* Requirements: