Create a file, like ~/.xmodmap and paste the following in it:
!
! Swap Caps_Lock and Control_L
!
remove Lock = Caps_Lock
remove Control = Control_L
keysym Control_L = Caps_Lock
keysym Caps_Lock = Control_L
| " Author: Bernardo Fontes <[email protected]> | |
| " Website: http://www.bernardofontes.net | |
| " This code is based on this one: http://www.cmdln.org/wp-content/uploads/2008/10/python_ipdb.vim | |
| " I worked with refactoring and it simplifies a lot the remove breakpoint feature. | |
| " To use this feature, you just need to copy and paste the content of this file at your .vimrc file! Enjoy! | |
| python << EOF | |
| import vim | |
| import re | |
| ipdb_breakpoint = 'import ipdb; ipdb.set_trace()' |
| #!/usr/bin/env python | |
| import curses | |
| import curses.textpad | |
| import time | |
| stdscr = curses.initscr() | |
| #curses.noecho() | |
| #curses.echo() |
Create a file, like ~/.xmodmap and paste the following in it:
!
! Swap Caps_Lock and Control_L
!
remove Lock = Caps_Lock
remove Control = Control_L
keysym Control_L = Caps_Lock
keysym Caps_Lock = Control_L
| #!/usr/bin/env python | |
| # | |
| # Adds the ability to add / modify tasks using a "blocks:" attribute, | |
| # the opposite of "depends:". | |
| # | |
| # This script acts as an on-modify, on-add and on-launch hook at the same time. | |
| # | |
| ### SETUP | |
| # Save this file as | |
| # ~/.task/hooks/on-modify.blocks_attr.py |
| zfs list -H -o name -t snapshot | xargs -n1 zfs destroy |
Based on this stackoverflow's answer.
To untrack a single file that has already been added/initialized to your repository, i.e., stop tracking the file but not delete it from your system use:
git rm --cached filename
To untrack every file that is now in your .gitignore:
First commit any outstanding code changes, and then, run this command:
Not for everyone. Each programmer has their own appreciation of what is good coding music.
(From most influential to least)
Using xclip to copy terminal content to the clip board:
Say you want to pipe shell output to your clipboard on Linux. How would you do it? First, choose the clipboard destination, either the Mouse clip or the system clipboard.
For the mouse clipboard, pipe straight to xclip:
echo 123 | xclip
For the system clip board, pipe to xclip and select clip directly: