This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/boot/bzImage | |
# Linux kernel userspace initialization code, translated to bash | |
# (Minus floppy disk handling, because seriously, it's 2017.) | |
# Not 100% accurate, but gives you a good idea of how kernel init works | |
# GPLv2, Copyright 2017 Hector Martin <[email protected]> | |
# Based on Linux 4.10-rc2. | |
# Note: pretend chroot is a builtin and affects the current process | |
# Note: kernel actually uses major/minor device numbers instead of device name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Set the title of the Terminal to the currently open file | |
function! SetTerminalTitle() | |
let titleString = expand('%:t') | |
if len(titleString) > 0 | |
let &titlestring = expand('%:t') | |
" this is the format iTerm2 expects when setting the window title | |
let args = "\033];".&titlestring."\007" | |
let cmd = 'silent !echo -e "'.args.'"' | |
execute cmd | |
redraw! |