I mainly use Java (with Gradle) and JavaScript (recently Vue). I recently had the opportunity to migrate my PC, so I will summarize what I did during setup.
By the way, it also includes Keyboard settings, Docker installation, and settings to read Markdown files from Vim, but Keyboard behaves a bit like a Mac (press the left side of the space for alphanumeric characters, press the right side for Japanese). It is a setting of.
The first update and upgrade take time. Then autoremove is done because you can erase the ones that are no longer needed as a result of upgrading.
sudo apt-get update
sudo apt-get upgrade
sudo apt-get autoremove
sudo apt-get install build-essential vim
Until now, .alias view =" vim -R "
was added in .bashrc
, but it seems that it can be associated without permission after installing vim.
In .bashrc, just change histsize etc.
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=5000
HISTFILESIZE=5000
#Do not record commands that are meaningless even if left
HISTIGNORE='ls:bg:fg:history'
#Enables time output and tabs to make it easier to handle with awk etc.
HISTTIMEFORMAT='%F %T '
As for .profile, there is no special action here because it only adds the path related to the tool to be inserted.
I have a preference for .vimrc, so it may be difficult for some people to use it. I want to display 2 spaces for tabs, display the current line, display full-width spaces, link with the markdown preview plug-in, and add highlights for Gradle.
set title
set showmatch
set tabstop=2
set shiftwidth=2
set expandtab
"set autoindent
set encoding=utf-8
syntax enable
set backspace=indent,eol,start
set hlsearch
set smartcase
set cursorline
set list
set listchars=tab:>\ ,trail:_
set ic
highlight SpecialKey ctermfg=darkgray
highlight NonText ctermfg=darkgray
highlight ZenkakuSpace cterm=underline ctermfg=darkgray
match ZenkakuSpace / /
highlight DiffAdd cterm=bold ctermfg=10 ctermbg=22
highlight DiffDelete cterm=bold ctermfg=10 ctermbg=52
highlight DiffChange cterm=bold ctermfg=10 ctermbg=17
highlight DiffText cterm=bold ctermfg=10 ctermbg=21
" instant-Added markdown settings
let g:instant_markdown_autostart = 0
" Gradle Highlight
au BufNewFile,BufRead *.gradle setf groovy
Keyboard settings are a bit cumbersome.
At this point, you will be able to input Japanese. However, if this is left as it is, no conversion and Caps Lock behavior will be inconvenient, so we will make further changes.
This setting is exported as keymap.txt, so it is expected to be usable if imported. However, as it is, the behavior of Caps Lock remains the same, so I will add another effort.
There is a file that defines keyboard behavior in / usr / share / X11 / xkb / symbols / jp
. (Take a backup before making changes)
There are 3 lines starting with key <CAPS>
(one of them is related to Mac, so ignore it), so replace it as follows. (Log out and log in to reflect) key <CAPS> {[Control_L >>]};
The expected behavior is CAPS + A
and Ctrl + A
, but the actual situation has no effect, so some settings may be wrong. However, at least with this setting, the behavior of Caps Lock (case change, input mode, etc.) itself could be sealed, so it is good for the time being that it was able to satisfy at least.
Yarn install
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && sudo apt-get install -y yarn
This is fine for yarn installation itself, but since the node version is old (4.x), node is installed separately.
Nodejs install
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get install -y nodejs
Installing Node.js via package manager | Node.js
OpenJDK install
sudo apt-get install openjdk-8-jdk
Eclipse, Gradle install
After downloading from the next, expand it, add the directory to mv in / opt, and add the description to .profile
and pass it through the path.
As an aside, the latest version of Eclipse (Oxygen) was pretty easy to use. Gradle was usable as a matter of course, and the UI was clean.
Google Cloud SDK install
Follow the steps below to perform the installation. Extract tar.gz
, mv the directory in / opt, and execute ./google-cloud-sdk/install.sh
to install. After that, initialize with gcloud init
. Perform an authentication operation in your browser. Similarly, I added the description to .profile
and passed the path.
Quickstart for Linux | Cloud SDK Documentation | Google Cloud Platform
Docker install
I followed the steps below. It was a little troublesome. Even when not in use, it gets in the way if it starts moving without permission, so it is disabled after installation.
sudo apt-get install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt-get update
sudo apt-get install docker-ce
sudo systemctl status docker
sudo systemctl disable docker
Get Docker CE for Ubuntu | Docker Documentation
sudo npm -g install instant-markdown-d
You can use ʻinstant-markdown.vim in the repository as soon as you install it in
~ / .vim / plugin / instant-markdown.vim`Basically, there are few problems, but it is inconvenient because Caps Lock cannot be used as Ctrl. There may be a way to install it and solve it, but I don't want to do it just to replace Caps Lock, so it would be nice if I could just rewrite a certain file. If you know it, please recommend it.
That's all for your reference.