Skip to content

Instantly share code, notes, and snippets.

View rajinder-yadav's full-sized avatar

Rajinder Yadav rajinder-yadav

  • DevMentor.org Corp.
  • Toronto, Ontario, Canada
View GitHub Profile
@rajinder-yadav
rajinder-yadav / vlc-ubuntu.md
Last active December 9, 2018 15:41
Fixing Ubuntu crashing and choppy playback

Ubuntu VLC fixes

To fix the crashing, simply upgrade VLC. First you will need to uninstall the default VLC.

Check if VLC is installed, which it should be.

sudo dpkg -l|grep vlc
@rajinder-yadav
rajinder-yadav / broken-pkg.md
Last active October 2, 2021 19:21
Ubuntu Linux - Fixing a broken package

Fixing a broken package on Ubuntu

Things to try to fix a broken package in Ubuntu Linux.

sudo apt-get install -f

Search for the package name and existence, narrow the proper name down.

@rajinder-yadav
rajinder-yadav / grub2-rescue.md
Last active October 28, 2021 10:41
Reinstall Grub2 on openSUSE TW & Ubuntu Linux

Reinstall Grub2 on Ubuntu Linux

openSUSE TW instructions

You will need to do 2 things, in this order:

  1. Mount the root volume
  2. Mount the boot volume

For openSUSE TW, the boot volume mount point is, "/boot/efi".

@rajinder-yadav
rajinder-yadav / keybindings.json
Last active February 27, 2025 09:03
VSCode shortcuts Linux
// Place your key bindings in this file to overwrite the defaults
[
{
"key": "ctrl+shift+left",
"command": "-workbench.action.terminal.resizePaneLeft",
"when": "terminalFocus"
},
{
"key": "ctrl+shift+right",
"command": "-workbench.action.terminal.resizePaneRight",
@rajinder-yadav
rajinder-yadav / user-setting-linux
Last active February 27, 2025 09:02
VSCode settings Linux
{
// Control the cursor animation style, possible values are 'blink', 'smooth', 'phase', 'expand' and 'solid'
// Controls the cursor style, accepted values are 'block', 'block-outline', 'line', 'line-thin', 'underline' and 'underline-thin'}
"editor.accessibilitySupport": "off",
"editor.autoClosingBrackets": "always",
"editor.autoClosingQuotes": "always",
"editor.copyWithSyntaxHighlighting": false,
"editor.cursorBlinking": "blink",
"editor.cursorStyle": "block",
"editor.fontFamily": "FiraCode Nerd Font, Regular",
@rajinder-yadav
rajinder-yadav / vscode-extension.md
Last active February 27, 2025 09:04
VSCode Extension List
#!/usr/bin/env bash
# List all installed extensions
# vc --list-extensions > /tmp/vscode-ex.txt
# vc --list-extensions | e -
# Linux
vc=/opt/local/apps/VSCode-linux-x64/bin/code-insiders
# MacOS
@rajinder-yadav
rajinder-yadav / keybindings.json
Last active January 16, 2023 18:26
VSCode custom shortcuts - MacOS
// Place your key bindings in this file to overwrite the defaults
[
{
"key": "alt+down",
"command": "-workbench.action.terminal.focusNextPane",
"when": "terminalFocus"
},
{
"key": "alt+right",
"command": "-workbench.action.terminal.focusNextPane",
@rajinder-yadav
rajinder-yadav / macos_setup.md
Last active November 11, 2021 00:17
Fixing key repeat for macos
@rajinder-yadav
rajinder-yadav / tmux.conf
Created October 26, 2017 21:57
TMUX configuration
set-option -g mouse on
set -g base-index 1
set -g pane-base-index 1
unbind-key C-b
set-option -g prefix C-a
set -g default-terminal "screen-256color"
set -g status-bg cyan
@rajinder-yadav
rajinder-yadav / object-clone.md
Created May 2, 2017 16:04
Cloning objects using spread and lodash

Object Cloning

To shallow clone an object, just use the JavaScript spread operator.

To perform a deep clone, make use of lodash deepClone.

import { cloneDeep as _cloneDeep } from "lodash";

const obj = {