Git Product home page Git Product logo

configbackup's Introduction

Emacs

My Emacs Config

DROP Env 环境变量

Install zsh, prezto first, then

ln -sf `pwd`/env/myzshenv ~/.myzshenv
ln -sf `pwd`/env/zpreztorc ~/.zpreztorc
echo "source \"${HOME}/.myzshenv\"" >> ~/.zshenv

pyenv 注意事项,~​/.pyenv/shims 有时候会 break $PATH 的脚本,比如 “pyenv: envsubst/gettext… command not found” 试下 pyenv rehash pyenv/pyenv#1112 pyenv/pyenv#688

键位映射

keyboard-remap/readme.org

DROP Xmodmap 键位映射

ln -sf `pwd`/.Xmodmap ~/

Firefox Layout

set the pref toolkit.legacyUserProfileCustomizations.stylesheets to true in about:config copy ./firefox/chrome directory into ~/.mozilla/firefox/${some-hash-code}.dev-edition-default/

kwin 去除标题栏,安装 systemsettings,窗口控制

Terminal

Alacritty

Install alacritty fisrt

mkdir -p ~/.config/alacritty
ln -sf `pwd`/terminal/alacritty.yml ~/.config/alacritty/

Tmux

ln -sf `pwd`/terminal/.tmux.conf ~/

Truecolor and Italic support

https://github.com/syl20bnr/spacemacs/wiki/Terminal

tic -x -o ~/.terminfo `pwd`/terminal/xterm-24bit.terminfo

Vim

ln -sf `pwd`/.vimrc ~/

Inputrc

ln -sf `pwd`/.inputrc ~/

DROP Podman, Skopeo, Buildah, Podman Compose

阿里云 https://cr.console.aliyun.com/undefined/instances/mirrors 镜像加速器管理页

https://help.aliyun.com/document_detail/60750.html

说明 目前由于Docker Hub限制,导致使用镜像加速器后无法获取最新官方镜像。请暂时去掉加速器配置,直接连接Docker Hub获取。

# rootless mode
sudo touch /etc/subuid /etc/subgid
sudo usermod --add-subuids 200000-201000 --add-subgids 200000-201000 `whoami`
podman system migrate
# mirrors
mkdir -p ~/.config/containers
ln -sf `pwd`/container/registries.conf ~/.config/containers/registries.conf
sudo ln -sf `pwd`/container/registries.conf /etc/containers/registries.conf

podman-compose 要安装 devel 分支版本的 ~yay -S podman-compose-git~,release 版好久没更新了

podman rootless 资源限制权限问题:

~/.config/containers/storage.conf, /etc/containers/storage.conf 的 =addtionalimagesstores= 设置为 =/var/lib/mycontainers=

~sudo chmod -R a+rx /var/lib/mycontainers~

DROP Docker

sudo ln -sf `pwd`/container/override.conf /etc/systemd/system/docker.service.d/

Rime

file:rime/README.org

Polybar

install xorg-xrandr https://github.com/polybar/polybar

ln -sf `pwd`/polybar ~/.config/
ln -sf `pwd`/polybar/polybar.desktop ~/.config/autostart

Albert

Install Albert first, then install extensions, Pressing the spacebar on it activated extensions.

git clone --depth=1 https://github.com/albertlauncher/python.git ~/.local/share/albert/org.albert.extension.python/modules

BEGIN

pyenv

Install https://github.com/pyenv/pyenv

pyenv install miniconda3-latest
pyenv global miniconda3-latest
# https://stackoverflow.com/questions/58044214/installing-anaconda-with-pyenv-unable-to-configure-virtual-environment
# disable init of env "base"
conda config --set auto_activate_base false
conda update --all
conda install python=version

dotfiles

# flake8 忽略缩进警告,调整每行默认长度
# pycodestyle 忽略缩进警告,调整每行默认长度
ln -sf `pwd`/python/.pip ~/.pip
ln -sf `pwd`/python/.condarc ~/
ln -sf `pwd`/python/flake8 ~/.config
ln -sf `pwd`/python/pycodestyle ~/.config

virtual environment examples

venv (deployment projects)

https://docs.python.org/3/tutorial/venv.html

# dir path ./venv is for emacs lsp-python-ms server
python -m venv ./venv
source venv/bin/activate
deactivate
pip freeze > requirements.txt
pip install -f requirements.txt

conda virtual environment (machine-learning researches)

https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#

conda create --name(-n) machine-learning python=3.8
conda env export > environment.yml
conda env create -f environment.yml
conda activate machine-learning

# specifying a location for an environment
conda create --prefix ./envs jupyterlab
conda activate ./envs
conda deactivate

Rustfmt

ln -nsf `pwd`/rust/rustfmt ~/.config/
ln -sf `pwd`/rust/config ~/.cargo/

NodeJs

pnpm

DROP fnm

https://github.com/Schniz/fnm

curl -fsSL https://fnm.vercel.app/install | bash -s -- --install-dir "$HOME/.config/fnm"
mkdir ~/.config/fnm/zfunc
fnm completions --shell=zsh > ~/.config/fnm/zfunc/_fnm

DROP nvm

Install nvm

# npm get registry
npm config set registry https://registry.npm.taobao.org
# yarn config get registry
yarn config set registry https://registry.npm.taobao.org/

Proxy

显卡

自动最新驱动: linux-latest, linux-latest-nvidia, linux{num}-nvidia, nvidia-utils, lib32-nvidia-utils

linux-lastest 依赖 linux{num} linux-latest-nvidia 依赖 linux{num}-nvidia 上面都是同一个人打的包,依赖没问题,升级的时候得看 nvidia 的版本是否都升上去了

手动指定驱动版本,可以自由选择内核,nvidia驱动更新较慢,升级时小心处理冲突(比如有个别人打包的新版的nvidia-utils…) linux{num}, linux{num}-nvidia-{NUM}xx, nvidia-{NUM}-utils, lib32-nvidia-{NUM}xx-utils

ps: pacman IgnorePkg 好像无法完全杜绝冲突的情况

https://github.com/Askannz/optimus-manager

cp `pwd`/optimus-manager/optimus-manager.conf /etc/optimus-manager/optimus-manager.conf

jounalctl 看见 acpi 错误导致触摸板加载失败, 修改 /etc/default/grub 防止 acpi 错误

#GRUB_CMDLINE_LINUX_DEFAULT="splash quiet udev.log_priority=3 acpi_osi=! acpi_osi='Windows 2009'"
GRUB_CMDLINE_LINUX_DEFAULT="splash quiet intel_iommu=on udev.log_priority=3"

sudo update-grub

https://wiki.archlinux.org/index.php/PRIME

Emacs, ibus-rime 中文输入法

https://coldnew.github.io/576cfa12/ http://liyanrui.is-programmer.com/posts/13324.html https://yangyingchao.github.io/emacs/2014/11/17/emacs-ibus.html pacman -S xorg-font-util

ln -sf `pwd`/.xprofile ~/.xprofile

Bluetooth

一般情况

install pulseaudio-bluetooth, bluez-utils(providing the bluetoothctl)

$ bluetoothctl
> power on
> ...
> scan on
> ..
> pair 28:...
> ...
> connect 28:...

Pairing works, but connecting does not

https://wiki.archlinux.org/index.php/Bluetooth_headset#Pairing_works,_but_connecting_does_not

journalctl -xe, you might see bluetoothd[5556]: a2dp-sink profile connect failed for 00:1D:43:6D:03:26: Protocol not available, that may be due to the pulseaudio-bluetooth package not being installed.

https://wiki.archlinux.org/index.php/Bluetooth_headset#HFP_not_working_with_PulseAudio

PulseAudio does not detect my bluetooth headset microphone. I see no mention of microphone in the Bluetooth wiki nor the Bluetooth Headset wiki. https://bbs.archlinux.org/viewtopic.php?pid=1921917#p1921917/ https://bbs.archlinux.org/viewtopic.php?id=209979

Refused to switch profile to headset_head_unit: Not connected https://bbs.archlinux.org/viewtopic.php?id=251719 https://askubuntu.com/questions/831331/failed-to-change-profile-to-headset-head-unit

Xbox One Controller wireless

https://wiki.archlinux.org/index.php/Gamepad#Xbox_Wireless_Controller_/_Xbox_One_Wireless_Controller

要想 disable ertm 生效,之前需要先把之前的连接配置删掉(bluetoothctl -> remove …)

FAQ

A stop job is running for session c2 of user …

sudo systemctl edit systemd-timesyncd.service
[Service]
TimeoutStopSec=1s

save as “systemd-timesyncd.service.d/override.conf” file

https://www.reddit.com/r/archlinux/comments/4bawf7/a_stop_job_is_running_for_session_c2_of_user/

Kwin 下切换应用时缩略图模糊(blurry)/分辨率低

https://www.reddit.com/r/kde/comments/g3pr44/emacs_icon_in_thumnail_view_task_switcher_is/fnulmgd?utm_source=share&utm_medium=web2x&context=3

Right click the title bar, more, special application settings, appearance and fixes, app desktop launcher name, force, name of launcher file without extension.

wine 微信同样的方法可以解决

Downgrade

https://forum.manjaro.org/t/repair-station-workarounds-to-get-almost-stable-again-after-serious-breaking-updates/40172/2

manjaro deppin bug 超多,升级后如果发现系统不正常了,可以考虑一下将一些包降级处理 sudo pacman -S downgrade 比如: deepin-kwin 5.2.0.3 导致窗口无法移动 sudo downgrade deepin-kwin 选择之前没问题的版本 5.2.0.2

Installing dig & nslookup on ArchLinux

sudo pacman -S bind

git 中文路径编码

git config --global core.quotepath false

core.quotepath设为false的话,就不会对0×80以上的字符进行quote

https://git-scm.com/docs/git-config#git-config-corequotePath

kwin 崩了

https://archived.forum.manjaro.org/t/cant-move-windows-no-window-borders/90779 Can’t move windows. No window borders. can’t use alt-tab. can’t even move it.

kwin-x11 2>&1 1>/dev/null &

deepin-wm --replace &

dde 下找到 kwin shortcuts 配置文件 file:~/.config/kglobalshortcutsrc

kde 快捷键配置文件。。。 https://forum.kde.org/viewtopic.php?t=151477

XPS15 9570

https://wiki.archlinux.org/index.php/Dell_XPS_15_9570 archlinux 的文档真是个宝藏

BIOS 固件升级

https://wiki.archlinux.org/index.php/Dell_XPS_15_9570#EFI_firmware_updates

固件升级到 1.15.0,风扇噪音问题得到明显改善,1.16.0及以上版本,cpu Undervolting(手动降频)有些问题,暂时没必要更新

yay aur 安装出现 python 依赖问题

pyenv global system pyenv 修改了 python PATH,aur 上的依赖就找不到,编译时先将 python 路径设回系统默认

亮度

# xrandr | grep -v disconnected | grep connected
xrandr --output eDP-1-1 --brightness 0.5

字体

https://szclsya.me/zh-cn/posts/fonts/linux-config-guide/

battery & performance

https://github.com/georgewhewell/undervolt

https://github.com/AdnanHodzic/auto-cpufreq sudo pacman -S auto-cuprfreq

Steam Proton

proton 5.13 issue

ValveSoftware/Proton#4289 (comment)

sudo pacman -S vulkan-tools

vulkaninfo |grep deviceName

启动命令: DXVK_FILTER_DEVICE_NAME=”YOUR GPU DEVICENAME” %command%

intel wifi

https://archived.forum.manjaro.org/t/weak-wifi-signal-intel-wireless-3165/84579 https://archived.forum.manjaro.org/t/qca9377-network-manager-idle-disconnect-issue/142151

configbackup's People

Contributors

zsxh avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.