Récemment, j'ai étudié en préparant un environnement avec VM pour chaque langage backend, et récemment je gère la méthode de construction d'environnement avec Gist, mais en quelque sorte vers Qitta. * * Cependant, Gist est écrit en anglais.
environment
** C'est ici que vous créez un environnement virtuel pour CUI ou GUI à l'aide d'Ubuntu. **
Ruby on Rails Install latest version
terminal
# install in one time
sudo apt install autoconf bison build-essential libssl-dev libreadline-dev zlib1g-dev libncurses5-dev libffi-dev libgdbm-dev
# install rbenv
# rbenv is tool to manage a few of ruby versions and enable to change ruby ver. project by project.
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
source ~/.bashrc
git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
# Install ruby
rbenv install --list
rbenv install 2.〇.〇
rbenv global 2.〇.〇
# Instal yarn
# Rails6 needs webpacker, and Webpacker needs yarn to 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 update
sudo apt install yarn
# Install Rails
gem install rails --no-document
# install webpacker
# inner App
rails webpacker:install
Install RubyonRails by "apt install"
terminal
sudo apt install -y ruby ruby-dev build-essential
sudo apt install yarn
sudo gem install rails
Nodejs rails6 uses webpacker, which needs nodejs
terminal
# first, install nodejs and npm
sudo apt install -y nodejs npm
# install n-package
sudo npm install n -g
# by n-package, install node
sudo n stable
# uninstal old nodejs and npm, and re-login
sudo apt purge -y nodejs npm
exec $SHELL -l
# confirm
node -v
Rust when discord changed golang to Rust, I just tried this and coded a little.
terminal
sudo apt install build-essential
# install rust
curl https://sh.rustup.rs -sSf | sh
# add the pass
source $HOME/.cargo/env
Java
terminal
sudo apt update
sudo apt install git
sudo apt install openjdk-11-jdk
# confirmation
java --version
PHP Python
Recommended Posts