by Jan Malakhovski
A course focused on programming for POSIX-compatible Operating Systems, with some theory and practice of Operating System design on top.
If you are able to … and everything below — you’ll get …
First semester:
write (in vim) a) scripts in bash, b) primitive C programs with POSIX syscalls, and c) explain what’s going on behing the scenes (from these syscalls to CPU caches) — A;
one of {a), b), c)} is missing — B or C;
only one of {a), b), c)} is peresent — D or E.
Second semester: WIP.
Bootstrap this course.
Learn vim
. Run vimtutor
to start. Do all other homeworks (better, everything) in vim
.
Approved .vimrc
:
" Tab autocompletion
function InsertTabWrapper()
let col = col('.') - 1
if !col || getline('.')[col - 1] !~ '\k'
return "\<tab>"
else
return "\<c-p>"
endif
endfunction
imap <TAB> <C-r>=InsertTabWrapper()<CR>
set complete=.,k,b,t
"<<<
set encoding=utf-8
set nocompatible
">>>
set ttyfast
set nomodeline
filetype plugin indent on
"<<<
set tabstop=4
set shiftwidth=4
set softtabstop=4
set expandtab
">>>
set ruler
set relativenumber
set mouse=a
set undofile
nnoremap / /\v
vnoremap / /\v
set ignorecase
set smartcase
set gdefault
set incsearch
set showmatch
set hlsearch
set wrap
set textwidth=79
set formatoptions=qrn1
set colorcolumn=80
set list
set listchars=tab:▸\ ,eol:¬
"<<<
nnoremap <up> <nop>
nnoremap <down> <nop>
nnoremap <left> <nop>
nnoremap <right> <nop>
inoremap <up> <nop>
inoremap <down> <nop>
inoremap <left> <nop>
inoremap <right> <nop>
nnoremap j gj
nnoremap k gk
">>>
inoremap <F1> <ESC>
nnoremap <F1> <ESC>
vnoremap <F1> <ESC>
nnoremap ; :
set viminfo='20,\"50
set history=50
set autowrite
set guioptions=aegirL
syntax on
things between <<<
and >>>
markers are mandatory settings.
See