banner
biuaxia

biuaxia

"万物皆有裂痕,那是光进来的地方。"
github
bilibili
tg_channel

【Reprint】This is how to play with Ubuntu and look cool!

title: 【Reprint】This is How to Play with Ubuntu Coolly!
date: 2021-09-01 17:52:00
comment: false
toc: true
category:

  • Linux
  • Ubuntu
    tags:
  • Linux
  • Ubuntu
  • Learning

This article is reprinted from: This is How to Play with Ubuntu Coolly! - Juejin


Preface#

During our work or study, we often come into contact with Linux and want to try this system ourselves. However, due to a lack of systematic learning, it can be quite difficult to create our own working environment. To prevent everyone from stepping into the pits I have encountered, this blog was created. This blog will mainly focus on system settings, commonly used software installation, development environment setup, and system beautification, teaching you step by step how to build your own Ubuntu (based on Ubuntu 20.04.4 LTS) working environment from scratch.

First, let me show you my working environment:

  • Desktop

image

  • Dock

image

  • Files

image

System Settings#

Change Mirror Source#

Change the official source to domestic mirror sources, such as Alibaba, Huawei, NetEase, etc.;

Open Software and Updates, then select to download from Other Sites, and choose the mirror source site you want to set. You can also click on the right to select the best server, which will automatically choose the fastest based on your location;

image

Install Updates#

After changing the source, execute the following commands to update the system;

sudo apt update
sudo apt-get upgrade

Use Local Time Zone#

When using a dual system, the time of both systems may often be incorrect. You can use the following command to make Ubuntu use the local time zone;

timedatectl set-local-rtc 1

Uninstall Built-in "Useless" Software#

The "useless" software mentioned here varies from person to person. The author only provides suggestions. The recommended list of software to uninstall is as follows (there may be some not listed that are rarely used; readers can decide whether to uninstall them, and if needed later, they can be reinstalled);

  • thunderbird built-in email
  • rhythmbox music
  • gnome-mahjongg matching game
  • gnome-mines minesweeper
  • gnome-sudoku sudoku
  • aisleriot solitaire
  • simple-scan scanner
  • onboard on-screen keyboard
  • brasero disc burning tool
  • cheese webcam
  • libreoffice suite, replace with WPS

Common Software Installation#

Input Method#

  • Sogou Input Method for Linux

The software is jointly developed by the Sogou Input Method team and the Ubuntu Kylin team, meeting our daily input needs;

  • Installation

It is recommended to download the installation package and install it, download link, the downloaded installation package is as follows;

image

Then open the terminal in the current folder and enter the following command to install;

sudo dpkg -i sogoupinyin_2.3.1.0112_amd64.deb

image

Next, go to Settings -> Region and Language and click on the installed language;

image

Set the keyboard input method to fcitx, then apply it to the entire system, and then log out or restart to use it;
image

  • Note

When installing, there may be dependency-related issues. After executing the above command, you can enter the following command in the terminal to fix the dependency installation, and then execute the above installation command again;

sudo apt-get --fix-broken install

Browser#

  • Chrome
    Speaking of browsers, although Firefox is pre-installed in Ubuntu, I prefer to use Chrome. As the browser with the highest market share globally, it goes without saying. Microsoft's newly released Edge browser is also quite good, but it currently does not support Linux and may support it further in the future.
  • Installation

It is recommended to use the deb installation package. First, download the installation package, and then use the following command in the local terminal to install;

sudo dpkg -i google-chrome-stable_current_amd64.deb

image

  • Finished Product

image

QQ#

Go to the official website download the corresponding installation package, and then use the following command in the terminal to install;

sudo dpkg -i linuxqq_2.0.0-b2-1082_amd64.deb

image

  • Finished Product

image

WeChat#

  • Installation

It is recommended to use the web version. Although there is a wine version available online, it has many bugs, so the web version is recommended;

  • Create Shortcut

Open the web version of WeChat, then go to More Tools -> Create Shortcut in the browser settings, and a shortcut will appear on the desktop, just trust it;

image

  • Finished Product

image

Music Player#

  • NetEase Cloud Music

As a music software under NetEase, although it has lost many users due to copyright issues, it does not affect its growing popularity among users. Listening to music while studying or working is also a great way to relax and adjust one's state.

  • Installation

Download the Linux version installation package, and then use the following command in the terminal to install;

sudo dpkg -i netease-cloud-music_1.2.1_amd64_ubuntu_20190428.deb

image

  • Finished Product

image

Screenshot Tool#

  • flameshot
    Flameshot is a modern screenshot tool that can be used for annotation, blurring, and also supports uploading to imgur image hosting;
  • Installation
sudo apt install flameshot

image

  • Set Shortcut Key

Go to Settings -> Devices -> Keyboard, then scroll to the bottom where there is a + button. Click + to add a custom shortcut, set the name and command, and then click the top right to add it to set your desired screenshot shortcut key, for example, I set it to Ctrl + Alt + A, as shown below;

image

  • Finished Product

image

Image Editor#

  • Gimp

GIMP stands for GNU Image Manipulation Program, a free photo and image processing and creation tool developed by Peter Mattis and Spencer Kimhall, with powerful features. It supports various image processing tools, full-channel, multi-level undo operations to restore old appearances and image modifications, and supports numerous effect plugins, making it comparable to the famous image processing software Photoshop on the Windows platform;

  • Installation

You can install it directly using the following command;

sudo apt-get install gimp

image

  • Finished Product

image

Word Processing#

  • WPS

Ubuntu comes with the LibreOffice office suite, but it is more recommended to use WPS, which is more in line with the usage habits of our country.

  • Installation

First download the installation package, then use the following command in the local terminal to install;

sudo dpkg -i wps-office_11.1.0.9505_amd64.deb

image

  • Finished Product

image

Markdown Editor#

  • Typora

As a minimalist Markdown editor, it merges writing and previewing. It supports tables, code editing, drag-and-drop images, etc., making it very user-friendly. The reasons I like it are: beautiful, free, and cross-platform;

  • Installation

You can install it using the following commands in sequence;

wget -qO - https://typora.io/linux/public-key.asc | sudo apt-key add -

sudo add-apt-repository 'deb https://typora.io/linux ./'

sudo apt-get update

sudo apt-get install typora

image

  • Finished Product

image

Document Reader#

  • Okular

It can be said to be the best PDF reader in Linux, and it also supports viewing common formats such as CHM, EPub, etc.;

  • Installation

You can install it directly using the following command in the terminal;

sudo apt-get install okular

image

  • Finished Product

image

Mind Mapping#

  • XMind

Before doing things or writing, I like to create an overall mind map and then refine each part based on the mind map. XMind is just such a tool;

  • Installation

Go to download the installation package, and then use the following command in the terminal to install;

sudo dpkg -i XMind-2020-for-Linux-amd-64bit-10.1.2-202004142327.deb

image

  • Finished Productimage

Multimedia Player#

  • VLC

It supports numerous audio and video decoders and file formats, as well as DVD, VCD, and various streaming protocols. It can also be used as a unicast or multicast streaming server over high-speed network connections in IPv4 or IPv6. It integrates FFmpeg's decoders and the libdvdcss library, enabling it to play multimedia files and encrypted DVDs, making it the best choice for multimedia players in Linux;

  • Installation

You can install it directly using the following command in the terminal;

sudo snap install vlc

image

  • Finished Product

image

Screen Recording Software#

  • Kazam

Small yet powerful, easy to install, it allows you to choose between area recording or full-screen recording, and also has screenshot functionality;

  • Installation

You can install it directly using the following command in the terminal:

sudo apt install kazam
  • Finished Product

image

Video Editing Software#

  • OpenShot

OpenShot is a versatile video editor on Linux that can help you create videos with transitions and effects.

  • Installation

You can install it directly using the following command in the terminal;

sudo apt install openshot
  • Finished Product

image

Download Tool#

  • uGet

Uget (formerly known as Urlgfe) is a free and open-source download manager written in GTK+, cross-platform (Windows and GNU/Linux), supporting resume and categorized downloads, and uGet also has multi-threaded download capabilities;

  • Installation
sudo apt-get install uget

image

  • Finished Product

image

Development Environment Setup#

git Installation#

You can install it directly using the following command in the terminal;

sudo apt install git

image

Node.js Installation#

  • Installation

Download the corresponding version compressed package from the Taobao mirror source download, then unzip it to the path where you want to store it, for example, mine is /home/cunyu/soft/node-v12.16.2;

  • Configuration

After installing (unpacking), configure it in the /etc/profile configuration file;

export NODEJS_HOME=/home/cunyu/soft/node-v12.16.2
export PATH=$NODEJS_HOME/bin:$PATH
  • Change to Taobao Mirror Source
npm config set registry http://registry.npm.taobao.org/
  • Verification
node -v
npm -v

image

JDK Installation#

  • Installation

First, go to download the JDK version you want to install, then unzip it locally and move it to your desired location;

tar -zxvf jdk-11.0.7_linux-x64_bin.tar.gz

image

image

  • Configuration

Open the configuration file /etc/profile, and then add the following content;

export JAVA_HOME=/home/cunyu/Soft/jdk11.0.7
export PATH=$JAVA_HOME:$PATH

image

image

  • Verification

After installation and configuration, enter the following commands in the terminal to verify whether it was successful;

# Check version
java -version
# Compile
java
# Execute
javac

image

MiniConda Installation#

  • Installation

Go to download the corresponding version installation package, taking version 3.7 as an example, then in the terminal, align and grant execution permissions before executing;

chmod +x Miniconda3-latest-Linux-x86_64.sh 

sh Miniconda3-latest-Linux-x86_64.sh

After execution, it will prompt you to read the relevant permissions, then enter yes to agree, and it will ask you to specify the installation directory. Just press enter for the default, and finally wait for the installation to complete;

  • Configuration

Open the ~/.bashrc file and add the following content;

# Note to enter your own miniConda installation directory
export  PATH="/home/cunyu/miniconda3/bin:"$PATH
  • Verification

image

MySQL Installation#

Latest Version#

  • Installation
sudo apt-get install mysql-server

image

  • Set root User Password

After the installation process is complete, log in directly. At this time, the root user has no password set. When prompted for a password, just press enter;

myslq -u root -p

After logging in, use the following command to change the root user password. After exiting, log in again with the password you set;

SET PASSWORD FOR 'root'@localhost = PASSWORD('the password you want to set');

Specify Version#

  • Use the following command to check the installable versions;
apt-cache search mysql | grep mysql-server
  • Then use the following command to install;
sudo apt install mysql-server-5.7

Note#

If you need to use sudo to log in, then after logging in with sudo, use the following command to update, so you won't need to use sudo to log in again after exiting

use mysql;
select User,Host,plugin from user;
update user set Plugin='mysql_native_password'

VS Code Installation#

  • Installation

Go to download the corresponding installation package, and then use the following command in the terminal to install;

sudo dpkg -i code_1.44.2-1587059832_amd64.deb

image

  • Finished Product

image

IntelliJ IDEA Installation#

  • Installation

Download the corresponding installation package from the official website download and then unzip it;

tar -zxvf ideaIU-2020.1.tar.gz

Enter the IDEA/bin directory and execute idea.sh;

  • Create Shortcut

After opening IDEA, go to Configure -> Create Desktop Entry, and then enter the root user password;

image

Pycharm Installation#

  • Installation

Download the corresponding installation package from the official website download and then unzip it;

tar -zxvf pycharm-professional-2020.1.tar.gz

Enter the Pycharm/bin directory and execute pycharm.sh;

  • Create Shortcut

After opening Pycharm, go to Configure -> Create Desktop Entry, and then enter the root user password;

image

System Beautification#

Grub Beautification#

For readers who have installed dual or multiple systems and want their boot page to look a bit nicer, you definitely can't miss this.

Go here to choose your favorite theme and install it. Here, I chose Grub-theme-vimix;

  • Installation

Clone Grub-theme-vimix to your local machine, then use the following command to install it;

sudo ./install.sh -t -2 -b

Lock Screen Interface Beautification#

Directly modify the related configuration file: /etc/alternatives/gdm3.css, and then modify the #lockDialogGroup part of the code as follows;

#lockDialogGroup {
  background: #2c001e   
  url(file:///home/cunyu/imgs/lock.png);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
}

Beautification Tool Installation#

Before beautifying, you need to install gnome-tweak-tool. The installation command is as follows;

sudo apt-get install gnome-tweak-tool

image

Theme Installation#

  • Download

It is recommended to use this set of macOS style themes, download link ;

image

  • Installation

After unzipping the downloaded package, move it to the /usr/share/themes directory;

Icon Installation#

  • Download

This icon set is recommended, download link ;

image

  • Installation

After unzipping the downloaded package, move it to the /usr/share/icons directory;

Terminal Installation#

  • Installation

The built-in terminal in Ubuntu is already very powerful, but I recommend using ZSH;

You can install it using the following command in the terminal;

sudo apt install zsh

image

  • Set as Default Shell
chsh -s /usr/bin/zsh
  • Beautification

Install oh-my-zsh by using one of the following commands;

# via curl
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
# via wget
sh -c "$(wget -O- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

You can also install it using the following commands;

git clone git://github.com/robbyrussell/oh-my-zsh.git  ~/.oh-my-zsh
cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc

After installation, configure zsh by opening the ~/.zshrc configuration file;

Go to the theme list and choose your favorite theme, then change it in the above configuration. For example, my theme is Powerlevel10k, use the following command to download it, and then configure ZSH_THEME="powerlevel10k/powerlevel10k" in .zshrc.

git clone --depth=1 https://gitee.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/themes/powerlevel10k

Using this theme may cause garbled characters, so you need to install fonts. Go to font download link to choose your favorite font for download, then unzip and double-click to install it. After that, set the font in the terminal settings to one of the fonts you just installed, and restart the terminal.

image

  • Plugin Installation

    • zsh-syntax-highlighting: syntax highlighting;
    git clone https://github.com/zsh-users/zsh-syntax-highlighting.git $ZSH_CUSTOM/plugins/zsh-syntax-highlighting
    
    • zsh-autosuggestions: auto-completion;
    git clone git://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions
    
# Theme
ZSH_THEME="powerlevel10k/powerlevel10k"

# Plugins
# git

# zsh-syntax-highlighting will show green highlight for correct input and other colors for incorrect input
# git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh

# zsh-autosuggestions for automatic suggestion completion
git clone git://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh

# extra extraction
# z
plugins=(
    git zsh-syntax-highlighting zsh-autosuggestions extract z
)

Summary#

Thus, the installation of Ubuntu 18.04 is complete, and you can now enjoy tinkering with the installed system QAQ.

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.