2018-01-13 13:22:02 +08:00
|
|
|
|
---
|
|
|
|
|
title: "Quick start guide"
|
2018-05-31 21:17:38 +08:00
|
|
|
|
description: "A quick start guide which will tell you how to install and config SpaceVim, also provides a list of resources for learning SpaceVim."
|
2018-01-13 13:22:02 +08:00
|
|
|
|
---
|
|
|
|
|
|
|
|
|
|
# Quick start guide
|
|
|
|
|
|
2018-04-24 21:27:06 +08:00
|
|
|
|
If you haven’t seen SpaceVim at all yet, the first thing you should read is this guide.
|
2018-02-20 22:02:00 +08:00
|
|
|
|
It will give you a good idea of what SpaceVim is like,
|
2018-04-24 21:27:06 +08:00
|
|
|
|
show you how to install it, how to config it, and explain its features.
|
2018-02-20 22:02:00 +08:00
|
|
|
|
|
2018-01-13 13:22:02 +08:00
|
|
|
|
<!-- vim-markdown-toc GFM -->
|
|
|
|
|
|
|
|
|
|
- [Install](#install)
|
|
|
|
|
- [Linux and macOS](#linux-and-macos)
|
|
|
|
|
- [Windows](#windows)
|
2018-10-06 12:51:37 +08:00
|
|
|
|
- [Run in docker](#run-in-docker)
|
2018-04-24 21:27:06 +08:00
|
|
|
|
- [Configuration](#configuration)
|
2018-10-02 21:04:30 +08:00
|
|
|
|
- [Online tutor](#online-tutor)
|
2018-02-20 22:02:00 +08:00
|
|
|
|
- [Learning SpaceVim](#learning-spacevim)
|
2018-01-13 13:22:02 +08:00
|
|
|
|
|
|
|
|
|
<!-- vim-markdown-toc -->
|
|
|
|
|
|
2018-02-20 22:02:00 +08:00
|
|
|
|
## Install
|
2018-01-13 13:22:02 +08:00
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
At a minimum, SpaceVim requires `git` and `curl` to be installed. Both tools
|
2018-01-13 13:22:02 +08:00
|
|
|
|
are needed for downloading plugins and fonts.
|
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
If you are using Vim/Neovim in terminal, you also need to set the font of your terminal.
|
2018-01-13 13:22:02 +08:00
|
|
|
|
|
|
|
|
|
### Linux and macOS
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
curl -sLf https://spacevim.org/install.sh | bash
|
|
|
|
|
```
|
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
After SpaceVim being installed, launch `vim` and SpaceVim will **automatically** install plugins.
|
2018-01-13 13:22:02 +08:00
|
|
|
|
|
|
|
|
|
For more info about the install script, please check:
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
curl -sLf https://spacevim.org/install.sh | bash -s -- -h
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
### Windows
|
|
|
|
|
|
2018-04-01 01:51:54 +08:00
|
|
|
|
The easiest way is to download [install.cmd](https://spacevim.org/install.cmd) and run it as administrator, or install SpaceVim manually.
|
2018-02-20 22:02:00 +08:00
|
|
|
|
|
2018-10-06 12:51:37 +08:00
|
|
|
|
## Run in docker
|
|
|
|
|
|
|
|
|
|
```sh
|
|
|
|
|
docker pull spacevim/spacevim
|
|
|
|
|
docker run -it --rm spacevim/spacevim nvim
|
|
|
|
|
```
|
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
You can also load local config:
|
2018-10-06 12:51:37 +08:00
|
|
|
|
|
|
|
|
|
```sh
|
|
|
|
|
docker run -it -v ~/.SpaceVim.d:/home/spacevim/.SpaceVim.d --rm spacevim/spacevim nvim
|
|
|
|
|
```
|
|
|
|
|
|
2018-04-24 21:27:06 +08:00
|
|
|
|
## Configuration
|
|
|
|
|
|
2018-05-13 12:59:41 +08:00
|
|
|
|
The default configuration file of SpaceVim is `~/.SpaceVim.d/init.toml`. This is
|
|
|
|
|
an example for basic usage of SpaceVim. For more info, please checkout SpaceVim
|
|
|
|
|
documentation.
|
2018-04-24 21:27:06 +08:00
|
|
|
|
|
|
|
|
|
```toml
|
2019-01-22 07:50:55 +08:00
|
|
|
|
# This is a basic configuration example for SpaceVim
|
2018-04-24 21:27:06 +08:00
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
# All SpaceVim options are below [options] snippet
|
2018-04-24 21:27:06 +08:00
|
|
|
|
[options]
|
|
|
|
|
# set spacevim theme. by default colorscheme layer is not loaded,
|
|
|
|
|
# if you want to use more colorscheme, please load the colorscheme
|
2018-05-13 12:59:41 +08:00
|
|
|
|
# layer, the value of this option is a string.
|
2018-04-24 21:27:06 +08:00
|
|
|
|
colorscheme = "gruvbox"
|
2018-05-22 19:45:57 +08:00
|
|
|
|
colorscheme_bg = "dark"
|
2018-04-24 21:27:06 +08:00
|
|
|
|
# Disable guicolors in basic mode, many terminal do not support 24bit
|
2018-05-13 12:59:41 +08:00
|
|
|
|
# true colors, the type of the value is boolean, true or false.
|
2018-06-03 20:38:01 +08:00
|
|
|
|
enable_guicolors = true
|
2018-04-24 21:27:06 +08:00
|
|
|
|
# Disable statusline separator, if you want to use other value, please
|
|
|
|
|
# install nerd fonts
|
|
|
|
|
statusline_separator = "nil"
|
|
|
|
|
statusline_separator = "bar"
|
|
|
|
|
buffer_index_type = 4
|
2018-05-22 19:45:57 +08:00
|
|
|
|
# Display file type icon on the tabline, If you do not have nerd fonts
|
|
|
|
|
# installed, please change the value to false
|
2018-05-13 12:59:41 +08:00
|
|
|
|
enable_tabline_filetype_icon = true
|
2018-05-22 19:45:57 +08:00
|
|
|
|
# Display current mode text on statusline, by default It is disabled,
|
|
|
|
|
# only color will be changed when switch modes.
|
2018-05-22 19:58:39 +08:00
|
|
|
|
enable_statusline_display_mode = false
|
2018-04-24 21:27:06 +08:00
|
|
|
|
|
|
|
|
|
# Enable autocomplete layer
|
|
|
|
|
[[layers]]
|
2019-01-22 07:50:55 +08:00
|
|
|
|
name = "autocomplete"
|
|
|
|
|
auto-completion-return-key-behavior = "complete"
|
|
|
|
|
auto-completion-tab-key-behavior = "cycle"
|
2018-04-24 21:27:06 +08:00
|
|
|
|
|
|
|
|
|
[[layers]]
|
2019-01-22 07:50:55 +08:00
|
|
|
|
name = "shell"
|
|
|
|
|
default_position = "top"
|
|
|
|
|
default_height = 30
|
2018-02-20 22:02:00 +08:00
|
|
|
|
|
2018-05-13 12:59:41 +08:00
|
|
|
|
# This is an example for adding custom plugins lilydjwg/colorizer
|
|
|
|
|
[[custom_plugins]]
|
2019-01-22 07:50:55 +08:00
|
|
|
|
name = "lilydjwg/colorizer"
|
|
|
|
|
merged = false
|
2018-05-13 12:59:41 +08:00
|
|
|
|
```
|
2018-04-29 13:06:50 +08:00
|
|
|
|
|
2018-10-02 21:04:30 +08:00
|
|
|
|
## Online tutor
|
|
|
|
|
|
|
|
|
|
This is a list of online tutor for using SpaceVim as general IDE and programming language support:
|
|
|
|
|
|
|
|
|
|
- [use vim as general IDE](../use-vim-as-ide/): a general guide for using SpaceVim as IDE
|
|
|
|
|
|
2019-01-22 07:50:55 +08:00
|
|
|
|
A list of guide for programming language support:
|
2018-10-02 21:04:30 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<ul>
|
|
|
|
|
{% for post in site.categories.tutorials %}
|
|
|
|
|
<li>
|
|
|
|
|
<a href="{{ post.url }}">{{ post.title }}</a>
|
|
|
|
|
</li>
|
|
|
|
|
{% endfor %}
|
|
|
|
|
</ul>
|
|
|
|
|
|
2018-02-20 22:02:00 +08:00
|
|
|
|
## Learning SpaceVim
|
|
|
|
|
|
2018-10-02 21:04:30 +08:00
|
|
|
|
- [SpaceVim Documentation](../documentation). Also known as "The Book",
|
|
|
|
|
The SpaceVim Documentation will introduce you to the main topics important to using SpaceVim.
|
|
|
|
|
The book is the primary official document of SpaceVim.
|
2018-02-20 22:02:00 +08:00
|
|
|
|
- [Hack-SpaceVim](https://github.com/Gabirel/Hack-SpaceVim). Tell you how to hack SpaceVim.
|