這是本文件的舊版!
啟動系統內建的 SSH Server
# vim /etc/rc.conf
增加一行:
sshd_enable="YES"
# /etc/rc.d/sshd
安裝 gnuls
# cd /usr/ports/misc/gnuls ; make install clean
alias ls gnuls --color=auto setenv EDITOR vim setenv PAGER less setenv BLOCKSIZE K set prompt = '%n@%m:%~%# '
複製 make 的設定檔(若檔案已經存在就不需要)。
# cp /usr/share/examples/etc/make.conf /etc/
修改 make.conf,新增 MASTER_SITE_BACKUP 及預設語系等設定。
# CVSup update flags. Edit SUPFILE settings to reflect whichever distribution # file(s) you use on your site (see /usr/share/examples/cvsup/README for more # information on CVSup and these files). To use, do "make update" in /usr/src. # SUP_UPDATE=yes # SUP= /usr/local/bin/csup SUPFLAGS= -g -L 2 SUPHOST= cvsup.tw.FreeBSD.org SUPFILE= /usr/share/examples/cvsup/standard-supfile PORTSSUPFILE= /usr/share/examples/cvsup/ports-supfile DOCSUPFILE= /usr/share/examples/cvsup/doc-supfile X11BASE=${LOCALBASE} MASTER_SITE_BACKUP?= \ ftp://freebsd.csie.ncu.edu.tw/distfiles/${DIST_SUBDIR}/ \ ftp://freebsd.csie.nctu.edu.tw/pub/distfiles/${DIST_SUBDIR}/ MASTER_SITE_OVERRIDE?= ${MASTER_SITE_BACKUP} ... ... ... WITHOUT_X11=yes WITH_CHARSET=utf8 WITH_XCHARSET=complex
set nocompatible " Vim5 and later versions support syntax highlighting. Uncommenting the next " line enables syntax highlighting by default. syntax on set nu """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" " Text options """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" set noexpandtab set shiftwidth=4 set softtabstop=4 set tabstop=4 set backspace=2 set formatoptions+=mM " so that vim can reformat multibyte text(eg. Chinese) set enc=utf-8 set fileencoding=utf-8 set termencoding=big5 " Favorite file types set ffs=unix,dos nmap <leader>fd :set ff=dos<cr> nmap <leader>fu :set ff=unix<cr> " If using a dark background within the editing area and syntax highlighting " turn on this option as well set background=dark " Uncomment the following to have Vim jump to the last position when " reopening a file if has("autocmd") au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") \| exe "normal g'\"" | endif endif " Uncomment the following to have Vim load indentation rules according to the " detected filetype. Per default Debian Vim only load filetype specific " plugins. if has("autocmd") filetype indent on endif " The following are commented out as they cause vim to behave a lot " differently from regular Vi. They are highly recommended though. set showcmd " Show (partial) command in status line. "set showmatch " Show matching brackets. "set ignorecase " Do case insensitive matching "set smartcase " Do smart case matching "set incsearch " Incremental search "set autowrite " Automatically save before commands like :next and :make "set hidden " Hide buffers when they are abandoned "set mouse=a " Enable mouse usage (all modes) in terminals set ruler """""""""""""""""""""""""""""" " Status line """""""""""""""""""""""""""""" set laststatus=2 " Always hide the status line "func! CurDir() " return substitute(getcwd(), "/home/tacolin", "~/", "g") "endfunc " Format the status line "set statusline=\ %F%m%r%h\ %w\ \ CWD:\ %r%{CurDir()}%h\ \ \ Line:\ %l/%L set statusline=\ %F%m%r%h\ %w\ [%{&ff}]\ [ASCI:\%3.3b]\ [POS:%3l,%3v:%3p%%]\ [LN:%L]