add new post on quick ubuntu dev setup
This commit is contained in:
parent
2f96d8b8e2
commit
5010170ec1
2 changed files with 91 additions and 0 deletions
3
.vscode/settings.json
vendored
Normal file
3
.vscode/settings.json
vendored
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
{
|
||||||
|
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\bash.exe",
|
||||||
|
}
|
88
_posts/2018-06-13-ubuntu-quick-dev-setup.md
Normal file
88
_posts/2018-06-13-ubuntu-quick-dev-setup.md
Normal file
|
@ -0,0 +1,88 @@
|
||||||
|
---
|
||||||
|
title: "3 Steps How To Quickly Setup Ubuntu for Development"
|
||||||
|
permalink: "/ubuntu-dev-setup"
|
||||||
|
description: "In this post I go through how I quickly setup an Ubuntu machine for development"
|
||||||
|
keywords: ""
|
||||||
|
image: "git-github.jpg"
|
||||||
|
image-attrib: ""
|
||||||
|
---
|
||||||
|
|
||||||
|
Whenever I get a new Ubuntu machine I intend to use for development, I go through so many articles around the web just so I can install everything I need. This is because I work on several projects using different technologies.
|
||||||
|
|
||||||
|
So I decided to write this article for quickly setting up all I need on a new Ubuntu for development. Following these steps will enable you to quickly setup Node.js, Python, and Jekyll (Ruby). <!--more-->
|
||||||
|
|
||||||
|
If you need instructions on how to setup the technologies separately, this article is not for you. Feel free to come back later to check for the separate posts I will be writing for Node.js, Python, and Ruby.
|
||||||
|
|
||||||
|
## 3 Steps: Quickly setup Node.js, Python, and Ruby on your new Ubuntu machine:
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
1. Open a terminal, and type this to download the .deb installer of nodejs 8
|
||||||
|
```bash
|
||||||
|
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
|
||||||
|
```
|
||||||
|
|
||||||
|
1. Update your repositories. The terminal may have to ask your password before it proceeds.
|
||||||
|
```bash
|
||||||
|
sudo apt-get update
|
||||||
|
```
|
||||||
|
|
||||||
|
2. Install packages for development using nodejs, ruby, and python. This may take a while to finish (depending on your Internet connection speed).
|
||||||
|
```bash
|
||||||
|
sudo apt-get install -y nodejs ruby2.4 ruby2.4-dev build-essential dh-autoreconf make python3-pip libssl-dev libffi-dev python3-dev virtualenv python3-venv
|
||||||
|
```
|
||||||
|
|
||||||
|
When the install finishes, you now have Node.js, Python, and Ruby installed. To verify if they are successfully installed and check for each of their versions, type the following on your terminal.
|
||||||
|
```bash
|
||||||
|
# to check for Node.js version
|
||||||
|
node --version
|
||||||
|
# this will also work
|
||||||
|
node -v
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# to check for Python version
|
||||||
|
python --version
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# to check for Ruby version
|
||||||
|
ruby --version
|
||||||
|
```
|
||||||
|
|
||||||
|
Of course, this is not yet a complete setup because I still have to setup Angular CLI next, or React.js, or other frameworks/tools. But after this setup, I have all the package management tools I need to proceed with all other setups. :)
|
||||||
|
|
||||||
|
## Bonus: Here is how you can setup for Jekyll development:
|
||||||
|
[Jekyll](https://jekyllrb.com) is a technology that will "Transform your plain text into static websites and blogs." I use it for this very blog, hosted for free on Github Pages. When all you need is a quick way to put content online, you can never go wrong with it, believe me.
|
||||||
|
|
||||||
|
I will write more about Jekyll and Github Pages later, but for now, here's how I set it up.
|
||||||
|
1. Open a text editor, then add the following two lines at end of the file ```~/.bashrc```:
|
||||||
|
```bash
|
||||||
|
export GEM_HOME=$HOME/gems
|
||||||
|
export PATH=$HOME/gems/bin:$PATH
|
||||||
|
```
|
||||||
|
|
||||||
|
2. On your terminal, run the following to reflect the changes:
|
||||||
|
```bash
|
||||||
|
source ~/.bashrc
|
||||||
|
```
|
||||||
|
|
||||||
|
3. Then, proceed to install necessary Ruby Gems:
|
||||||
|
```bash
|
||||||
|
sudo gem update
|
||||||
|
gem install jekyll bundler
|
||||||
|
```
|
||||||
|
|
||||||
|
4. Go to jekyll project directory (if you already have one) or generate a new Jekyll, then install the dependencies:
|
||||||
|
```bash
|
||||||
|
bundle install
|
||||||
|
```
|
||||||
|
|
||||||
|
5. After installing the dependencies, you may now start the Jekyll server:
|
||||||
|
```bash
|
||||||
|
bundle exec jekyll serve
|
||||||
|
```
|
||||||
|
|
||||||
|
Your website will be accessible at ```http://localhost:4000``` by default.
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue