Linux 笔记
本文最后更新于 156 天前,其中的信息可能已经有所发展或是发生改变。

这篇Linux笔记用来记录一些Linux的设置、常用的软件、常见的问题

Proxy Settings

Terminal proxy

终端环境代理设置

export http_proxy=http://username:[email protected]:port
export ftp_proxy=http://username:[email protected]:port
export telnet_proxy=http://username:[email protected]:port
unset http_proxy
unset https_proxy
# example
export http_proxy=http://127.0.0.1:10809
export https_proxy=http://127.0.0.1:10809

Snapd 代理设置

Refer: https://snapcraft.io/docs/system-options
proxy.{http,https,ftp}
These options may be set to change the proxies to be used by the system when communicating with external sites that speak the respective protocols. Available since snapd 2.28.

sudo snap set system some.option="some value"
sudo snap set system some.option
sudo snap set system proxy.http="http://<proxy_addr>:<proxy_port>"
sudo snap set system proxy.https="http://<proxy_addr>:<proxy_port>"

Git 代理设置

可以修改~/.gitconfig

git config --global http.proxy socks5://127.0.0.1:10808
git config --global https.proxy socks5://127.0.0.1:10808
git config --global http.proxy http://127.0.0.1:10808
git config --global https.proxy http://127.0.0.1:10808
git config --global --unset http.proxy
git config --global --unset https.proxy

常见的问题

KDE Plasma

Snaps in application launcher

After installing snaps via discover or cli they do not appear in the application launcher. Flatpack apps work just fine. Any idea how to fix this? I’m using kde neon.

https://www.reddit.com/r/kde/comments/9pjos2/snaps_in_application_launcher/

If you are using zsh, your system may not read in the necessary PATHs that are set in /etc/profile.d/apps-bin-path.sh. As a result, KDE does not see the desktop files for the snaps.

To fix this, open your /etc/zsh/zprofile as root and add the following line:

emulate sh -c 'source /etc/profile'

This may also fix some other items related to the shell configuration. If all you want is to fix the paths, you can also just add the following line instead:

emulate sh -c 'source /etc/profile.d/apps-bin-path.sh'

Input method(Add Chinese)

Using fcitx

sudo apt install fcitx-rime

Then logout the session, go settings-> fcitx-configuration add your language

Or using ibus

sudo apt install ibus-rime
ibus restart
ibus engine rime

Then go to language, add a new input source

How do I clear the DNS cache?

refer: https://askubuntu.com/questions/2219/how-do-i-clear-the-dns-cache/929478#929478

From Ubuntu 17.04 and onwards, systemd-resolve is used for DNS. You can flush systemd’s caches like so:

sudo systemd-resolve --flush-caches

Run php program in apache2

Sometimes we easily forget one php-extension libapache2-mod-php<version>
So if you got this problem — When opened your website, it showed php code instead of web interface

Gwenview cannot display documents of type image/webp

archlinux需要安装这个包qt5-imageformats
参考: https://bugs.kde.org/show_bug.cgi?id=414800


Useful software

ScreenShot

1.Flameshot

Flameshot-Powerful yet simple to use screenshot software

Developer website: https://github.com/lupoDharkael/flameshot

@这个可以和windows下的snipaste有一拼了

功能上能添加类似snipaste那种坐标描点就好了

2. 压缩工具p7zip

sudo apt install p7zip-full

加密文件

7za a -tzip -p -mem=AES256 xxx.zip  [要加入压缩包的文件]
暂无评论

发送评论 编辑评论


|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇