Ubuntu20.04 桌面配置

Ubuntu20.04 桌面配置

apt-fast 多线程下载

多线程下载,基于apt,apt-get,使用方式,将apt替换为apt-fast即可,安装方式如下
## apt-fast
sudo add-apt-repository ppa:apt-fast/stable
sudo apt install apt-fast
sudo apt-fast update

更换国内源

使用国内源好处不仅仅是速度快,而且国内源还具有很多国人自己打包管理的软件,例如fcitx5
## mirrors.aliyun.com
sudo vim /etc/apt/sources.list
:%s/xxx.xxx/mirrors.aliyun/

基本软件安装

软件功能
vim文本编辑器
feh查看图片,可设置桌面壁纸
compton类似picom,透明化
ranger终端文件管理器
zshshell,个人使用,尽量不要在工作环境使用
makec工程编译器
xorg-devx11开发环境,安装后可以自行编译dwm
ubuntu-restricted-extras基本包含所有基本的媒体编码器
synaptic软件包管理器
tlp tlp-rdw电池管理工具
timeshift系统备份工具
preload默认记录使用率最高的软件,添加如内存,打开该应用会提速
vim-gtk将vim中的文本内容复制到系统剪切板,~/.vimrc set clipboard=unnamedplus
shotwell自动切换壁纸
flameshot截屏软件
sudo apt-fast install vim git curl feh compton ranger zsh gcc make xorg-dev ubuntu-restricted-extras synaptic tlp tlp-rdw timeshift preload vim-gtk shotwell flameshot
#alacritty
sudo add-apt-repository ppa:aslatter/ppa
sudo apt-fast install alacritty

oh-my-zsh安装以及插件配置

sh -c "$(wget https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh -O -)"

git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions && 
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

## ~/.zshrc中的plugins=(git)添加
zsh-autosuggestions zsh-autosuggestions

## ~/.zshrc添加
alias ai='sudo apt-fast install'
alias au='sudo apt-fast update && sudo apt-fast upgrade'
alias gu='git config --global url."https://hub.fastgit.org".insteadOf https://github.com'
alias gr='git config --global --unset url.https://github.com/.insteadof'
alias setproxy="export ALL_PROXY=socks5://127.0.0.1:1089" 
alias unsetproxy="unset ALL_PROXY"
alias ra='ranger'
export RANGER_DEFAULT_RC=FALSE

修改键位

以下是caplock和esc键位互换	
xmodmap ~/.xmodmap 
## vim ~/.xmodmap
clear lock
!!keycode 0x42 = Escape
keycode 66 = Escape NoSymbol Escape
keycode 9 = Caps_Lock NoSymbol Caps_Lock

ranger

  • 生成个人配置文件
  • 个人使用的shellrc(如:bashrc,zshrc)中添加取消加载默认配置
  • 添加home文件夹图标和文件类型图标插件
  • 预览图片
#生成个人ranger配置文件
ranger --copy-config=all
#取消加载默认配置
export RANGER_DEFAULT_RC=FALSE
#nerd_fonts 字体 
git clone https://github.com/ryanoasis/nerd-fonts.git --depth 1
./install.sh
#ranger 图标插件
git clone https://github.com/alexanderjeurissen/ranger_devicons ~/.config/ranger/plugins/ranger_devicons
echo "default_linemode devicons" >> $HOME/.config/ranger/rc.conf
#vim ~/.config/ranger/rc.conf
chmod +x ~/.config/ranger/scope.sh
set preview_images true
set preview_images_method w3m
#默认查看图片使用的是w3m,如果未能正常预览图片
#可以尝试更换终端,如alacritty
#或者使用其他预览图片的方式
sudo apt-fast install python3-pip
pip install ueberzug
vim ~/.config/ranger/rc.conf
set preview_images_method ueberzug

github 镜像加速

raw.github.com文件建议关闭
git config --global url."https://hub.fastgit.org".insteadOf https://github.com
git config --global --unset url.https://github.com/.insteadof

Firefox优化

修改后,硬件加速渲染网页
layers.acceleration.force-enabled true
gfx.webrender.all	true

修改登陆界面

git clone https://github.com/thiggy01/change-gdm-background
##修改登陆界面颜色
sudo ./change-gdm-background \#130c0e
sudo ./change-dgm-background ~/xx/xx.jpg

fcitx5

bash | sudo apt install fcitx5 fcitx5-*
mkdir ~/config/fcitx5
vim ~/.config/fcitx5/config
[Hotkey]
# Enumerate when press trigger key repeatedly
EnumerateWithTriggerKeys=True
# Skip first input method while enumerating
EnumerateSkipFirst=False
[Hotkey/TriggerKeys]
#快捷键
0=Control+Shift+Control_L
1=Zenkaku_Hankaku
2=Hangul
[Hotkey/AltTriggerKeys]
0=Shift_L
[Hotkey/EnumerateForwardKeys]
0=Control+Shift_L
[Hotkey/EnumerateBackwardKeys]
0=Control+Shift_R
[Hotkey/EnumerateGroupForwardKeys]
0=Super+space
[Hotkey/EnumerateGroupBackwardKeys]
0=Shift+Super+space
[Hotkey/ActivateKeys]
0=Hangul_Hanja
[Hotkey/DeactivateKeys]
0=Hangul_Romaja
[Hotkey/PrevPage]
0=Up
[Hotkey/NextPage]
0=Down
[Hotkey/PrevCandidate]
0=Shift+Tab
[Hotkey/NextCandidate]
0=Tab
[Hotkey/TogglePreedit]
0=Control+Alt+P
[Behavior]
# Active By Default
ActiveByDefault=False
# Share Input State
ShareInputState=No
# Show preedit in application
PreeditEnabledByDefault=True
# Show Input Method Information when switch input method
ShowInputMethodInformation=True
# Show Input Method Information when changing focus
showInputMethodInformationWhenFocusIn=False
# Show compact input method information
CompactInputMethodInformation=True
# Show first input method information
ShowFirstInputMethodInformation=True
# Default page size
DefaultPageSize=5
# Force Enabled Addons
EnabledAddons=
# Force Disabled Addons
DisabledAddons=
# Preload input method to be used by default
PreloadInputMethod=True
vim ~/.config/fcitx5/profile
[Groups/0]
# Group Name
Name=Default
# Layout
Default Layout=us
# Default Input Method
DefaultIM=pinyin

[Groups/0/Items/0]
# Name
Name=keyboard-us
# Layout
Layout=

[Groups/0/Items/1]
# Name
Name=pinyin
# Layout
Layout=

[GroupOrder]
0=Default

开机启动

搜索startup application
- 添加fcitx5(fcitx5)
- 添加compton(compton -b)
- 添加flameshot(flameshot)

快捷键添加

设置搜索快捷键(shortkey)
添加自定义
例如:
	alacritty
	rofi -show drun
	flameshot gui

美化

sudo apt-get install gnome-tweak-tool
sudo apt-get install gnome-shell-extensions
  • 1
    点赞
  • 7
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值