Skip to content

Instantly share code, notes, and snippets.

Nitish Garg nitish6174

View GitHub Profile
View Code analysis tools.md

Code analysis tools

Python

  • pdb : The Python Debugger
  • cProfiler : Get profile for running time of various functions
  • KCacheGrind : Generate call graph of functions
  • valgrind : Profile memory usage by program
  • gperftools : Set of tools for performance profiling and memory checking. Generates a call graph output
  • pylint : Source code syntax & linting checker
  • pyreverse : Creates UML diagrams for python code. Included in pylint
@nitish6174
nitish6174 / .vimrc
Last active Oct 8, 2016
Improve vim by installing vundle package manager, following plugins and using keyboard shortcuts
View .vimrc
" --------------------------------------------------
" Vundle package manager settings
" --------------------------------------------------
set nocompatible
filetype off
" ---------- Set path of vundle file ----------
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
@nitish6174
nitish6174 / ubuntu-gnome-extensions.md
Created Oct 4, 2016
List of useful Ubuntu Gnome extensions to install
View ubuntu-gnome-extensions.md
  • Alternatetab (Ungroup windows of same type)
  • Applications menu (Windows OS style Applications menu)
  • Caffeine (Disable autosuspend)
  • Clipboard indicator (Clipboard history)
  • Drop down terminal (Alternative to Guake terminal)
  • Easyscreencast (Screen recording)
  • Laine (Control volume of each application)
  • Media keys (Music control buttons on topbar)
  • Media player indicator (Music controller for topbar)
  • Pixel saver (Brings title bar applications to topbar)
@nitish6174
nitish6174 / ubuntu-gnome-themes.md
Last active Oct 4, 2016
List of dark themes for Ubuntu Gnome
View ubuntu-gnome-themes.md
  • Adapta
  • Arc
  • Flatabulous
  • Nebula
  • Numix
  • Paper
  • Super flat remix (Icon theme)
@nitish6174
nitish6174 / sublime_packages.md
Last active Oct 4, 2016
List of useful Sublime text packages
View sublime_packages.md
  • Manager and explorer :
    • Package manager : To manage all your sublime packages
    • SideBarEnhancements : Gives an extensive menu for renaming, duplicating file etc from the file explorer pane (The left column)
  • Themes & Color schemes :
    • Monokai Extended
    • Predawn
    • Theme - Afterglow
    • Theme - Asphalt
    • Theme - Brogrammer
    • Theme - Flatland
@nitish6174
nitish6174 / git_visualize.md
Last active Oct 10, 2016
Git alias for a better commit visualizaion
View git_visualize.md
  1. Add the following block in gitconfig file :
[alias]  
    graph1 = log --graph --abbrev-commit --decorate --format=format:'%C(blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(bold white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all
    graph2 = log --graph --abbrev-commit --decorate --format=format:'%C(blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n''%C(bold white)%s%C(reset) %C(dim white)- %an%C(reset)' --all
  1. Now run git graph1 or git graph2 in your project folder to view a nice git log
@nitish6174
nitish6174 / mouse_cursor_using_keyboard.md
Last active Oct 6, 2018
Settings to control mouse cursor using keyboard
View mouse_cursor_using_keyboard.md
  1. Open 'Settings' -> 'Universal Access' -> 'Pointing and clicking' -> 'Mouse keys'
  2. Turn that option ON
  3. Now you will be able to move cursor with numpad but the speed will be extremely slow.
  4. Run the following commands in terminal to set a good to do speed :
    sudo apt-get install xkbset
    xkbset ma 60 10 10 5 2
@nitish6174
nitish6174 / bashrc
Last active Jun 12, 2017
Bash aliases for the lazy typers
View bashrc
## Add sudo wherever needed
## list all files in current directory
alias ll="ls -alh"
## apt shorthands
alias sau="sudo apt-get update"
alias sai="sudo apt-get install"
sar() {
sudo apt-get autoremove
@nitish6174
nitish6174 / server_setup.md
Last active Nov 1, 2016
Commands to setup development tools on an Ubuntu server
View server_setup.md
sudo apt-get update
sudo apt-get upgrade
# --------------------------------------------------
# Basic programs
# --------------------------------------------------
sudo apt-get install openssh-server
sudo apt-get install vim
sudo apt-get install git
sudo apt-get install curl
You can’t perform that action at this time.