aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHumphrey Lin <[email protected]>2020-11-30 10:48:19 +0000
committerHumphrey Lin <[email protected]>2020-11-30 10:48:19 +0000
commit06d6429e795777effa4a2fb5f3b3c71445f3d135 (patch)
treea6238d966be89dc2d155cc9ae20f9ba70f4a8d40
parent6c0e55563b7ae36b8d3b5fa81d731cbcf9db4312 (diff)
downloaddotfiles-06d6429e795777effa4a2fb5f3b3c71445f3d135.tar.gz
dotfiles-06d6429e795777effa4a2fb5f3b3c71445f3d135.tar.bz2
dotfiles-06d6429e795777effa4a2fb5f3b3c71445f3d135.zip
Add a setup documents for manjaro
-rw-r--r--install.sh60
-rw-r--r--manjaro-startup.md36
2 files changed, 46 insertions, 50 deletions
diff --git a/install.sh b/install.sh
index 104dfa5..60881f1 100644
--- a/install.sh
+++ b/install.sh
@@ -11,67 +11,28 @@ check_is_sudo() {
usage() {
echo "Usage: sudo bash install.sh [OPTION]"
- echo " base - install base pkgs"
- echo " dotfiles - get dotfiles from GitHub and set soft links"
+ echo " dotfiles - link all dotfiles"
echo " all - install all things listed above"
}
-base_install() {
- echo "--------- Install Base Packages Now ---------"
- if command -v apt > /dev/null; then
- apt update
- apt upgrade
- apt install git \
- curl \
- cmake \
- build-essential \
- python3-dev \
- autojump \
- zsh \
- gcc \
- make \
-
- pkg-config autoconf automake \
- python3-docutils \
- libseccomp-dev \
- libjansson-dev \
- libyaml-dev \
- libxml2-dev
- else if command -v pacman > /dev/null; then
- pacman -S autojump
- else if command -v brew > /dev/null; then
- brew install autojump
- fi
- # Universal Ctags
- git clone [email protected]:universal-ctags/ctags.git
- (
- cd ctags
- ./autogen.sh
- ./configure
- make
- make install
- )
-}
-
get_dotfiles() {
# create subshell
(
echo "--------- Get Dotfiles Now ---------"
- read -r -p "It will remove the dotfiles folder if it exists and overwrite all dotfiles. Are you sure? [y/N] " response
+ read -r -p "It will remove the .dotfiles folder if it exists and overwrite all dotfiles. Are you sure? [y/N] " response
response=${response,,} # tolower
if [[ "$response" =~ ^(yes|y)$ ]]; then
cd "$HOME"
- rm -rf dotfiles
- git clone [email protected]:humpylin/dotfiles.git
-
- rm -rf .vimrc .tmux.conf .bashrc .zshrc .gitconfig
- ln -s dotfiles/.vimrc .vimrc
- ln -s dotfiles/.tmux.conf .tmux.conf
- ln -s dotfiles/.bashrc .bashrc
- ln -s dotfiles/.gitconfig .gitconfig
- ln -s dotfiles/.zshrc .zshrc
+ rm -rf .dotfiles
+ git clone https://github.com/humpylin/dotfiles .dotfiles
+
+ rm -rf .vimrc .tmux.conf .bashrc .zshrc
+ ln -s .dotfiles/.vimrc .vimrc
+ ln -s .dotfiles/.tmux.conf .tmux.conf
+ ln -s .dotfiles/.bashrc .bashrc
+ ln -s .dotfiles/.zshrc .zshrc
fi
)
}
@@ -87,7 +48,6 @@ main() {
check_is_sudo
if [[ $cmd == all ]]; then
- base_install
get_dotfiles
fi
}
diff --git a/manjaro-startup.md b/manjaro-startup.md
new file mode 100644
index 0000000..59d9024
--- /dev/null
+++ b/manjaro-startup.md
@@ -0,0 +1,36 @@
+# Manjaro Startup Notes
+
+Update software: `sudo pacman -Syu` #TODO: What is it different from `sudo pacman -Syyu`
+
+Install some useful software:
+
+```bash
+sudo pacman -S yay
+yay -S google-chrome
+```
+
+## Natural Scrolling
+
+Open the `/etc/X11/xorg.conf.d/30-touchpad.conf` file, then add the natural scrolling option:
+
+```
+Section "InputClass"
+ ...
+ Option "Natural Scrolling" "true"
+ ...
+EndSection
+```
+
+## (China Specific) Install Proxy
+
+Use the command `sudo pacman -S ss-qt5`. In I3WM, it is difficult to set global proxy. It would be better to use SwitchyOmega in Chrome. First use `google-chrome-stable --proxy-server="<proxy_address>"` to launch chrome and download SwitchyOmega then use chrome as usual.
+
+## (China Specific) Install input sources
+
+Install fcitx first: `sudo pacman -S fcitx-im fcitx-configtool fcitx-googlepinyin`. Then add the following content to `~/.xprofile`.
+
+```
+export GTK_IM_MODULE=fcitx
+export QT_IM_MODULE=fcitx
+export XMODIFIERS="@im=fcitx"
+```