發新話題
打印

Swift 4 installation on Ubuntu 16.04

Swift 4 installation on Ubuntu 16.04

Extract and move Swift:
引用:
tar -xvf swift-DEVELOPMENT-SNAPSHOT-2017-10-20-a/
引用:
Computer:~/Downloads$ sudo mv ./swift-DEVELOPMENT-SNAPSHOT-2017-10-17-a-ubuntu16.04 /opt/swift4/
Next make Swift Global
引用:
echo 'export SWIFT_ROOT="/opt/swift4"' >> ~/.bashrc
echo 'export PATH="$SWIFT_ROOT/usr/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
Update:
引用:
sudo apt update
Check to make sure Swift Works:
引用:
swift --version
[ 本帖最後由 Net 於 2017-10-31 10:53 編輯 ]

TOP

https://alvinalexander.com/linux ... syntax-highlighting
引用:
What happen if :
E319: Sorry, the command is not available in this version: syntax on
In vim ...
type
引用:
:version
if small version without GUI, then ..
引用:
sudo apt install vim-gui-common
sudo apt install vim-runtime

TOP

My vimrc looks as followed:

set rtp+=$HOME/.vim/bundle/nerdtree
so $HOME/.vim/bundle/nerdtree/plugin/NERD_tree.vim

" execute pathogen
execute pathogen#infect()

" enable syntax
syntax on

" enable filetype plugin
filetype plugin indent on

" enable line numbers
set number

" Use 256 colours
set t_Co=256

" Splitting screens
nnoremap ,h <C-w>s
nnoremap ,v <C-w>v
nnoremap ,, <C-w><C-w>

" Mouse support
set mouse=a

" Some other configs
set tabstop=4
set autoindent
set shiftwidth=4
set shiftround
set showmatch
set ignorecase
set smartcase
set encoding=utf-8
set smarttab
set hlsearch
set incsearch
set history=1000
set undolevels=1000
set visualbell
set noerrorbells
set backspace=indent,eol,start
set background=dark
autocmd InsertEnter * set cul
autocmd InsertLeave * set nocul

" Nerdtree toggling
nmap <C-p> :NERDTreeToggle<CR>
map <F3> :NERDTreeFind<CR>
let g:NERDTreeMapActivateNode="<F3>"
let g:NERDTreeMapPreview="<F4>"
let g:NERDTreeShowHidden=1
" All system-wide defaults are set in $VIMRUNTIME/debian.vim and sourced by
" the call to :runtime you can find below.  If you wish to change any of those
" settings, you should do it in this file (/etc/vim/vimrc), since debian.vim
" will be overwritten everytime an upgrade of the vim packages is performed.
" It is recommended to make changes after sourcing debian.vim since it alters
" the value of the 'compatible' option.

" This line should not be removed as it ensures that various options are
" properly set to work with the Vim-related packages available in Debian.
runtime! debian.vim

" Uncomment the next line to make Vim more Vi-compatible
" NOTE: debian.vim sets 'nocompatible'.  Setting 'compatible' changes numerous
" options, so any other options should be set AFTER setting 'compatible'.
"set compatible

" Vim5 and later versions support syntax highlighting. Uncommenting the next
" line enables syntax highlighting by default.
if has("syntax")
  syntax on
endif

" 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("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
"endif

" Uncomment the following to have Vim load indentation rules and plugins
" according to the detected filetype.
"if has("autocmd")
"  filetype plugin 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)

" Source a global configuration file if available
if filereadable("/etc/vim/vimrc.local")
  source /etc/vim/vimrc.local
endif

:set rtp? shows me the following:

runtimepath=~/.vim,/var/lib/vim/addons,/usr/share/vim/vimfiles,/usr/share/vim/vim74,/usr/share/vim/vimfiles/after,/var/lib/vi
m/addons/after,~/.vim/after

[ 本帖最後由 Net 於 2017-10-21 22:41 編輯 ]

TOP

發新話題