From 0b9b42888d14712d7814a232d2439c6f17e4da93 Mon Sep 17 00:00:00 2001 From: Geoffrey Frogeye Date: Wed, 26 Jul 2017 04:34:10 +0200 Subject: [PATCH] Yes, I know. --- inputrc | 2 ++ scripts/install-prefs | 26 +++++++++++++++++--------- scripts/install-wsl | 11 +++++++++++ 3 files changed, 30 insertions(+), 9 deletions(-) create mode 100755 scripts/install-wsl diff --git a/inputrc b/inputrc index 9f4f421..4c211de 100644 --- a/inputrc +++ b/inputrc @@ -27,6 +27,8 @@ $if mode=vi Control-l: clear-screen set keymap vi-insert # these are for vi-insert mode + "jk": vi-movement-mode + "mù": vi-movement-mode "\e[A": history-search-backward "\e[B": history-search-forward Control-l: clear-screen diff --git a/scripts/install-prefs b/scripts/install-prefs index 160d2bf..cab5f7e 100755 --- a/scripts/install-prefs +++ b/scripts/install-prefs @@ -48,7 +48,7 @@ if which pacman &> /dev/null; then function installOne { # package pacman -Q $1 &> /dev/null if [ $? == 1 ]; then - sudo pacman -S $1 --noconfirm + sudo pacman -S $1 --noconfirm --needed fi } function installFileOne { # file @@ -172,7 +172,7 @@ if [ $TERMUX == 1 ]; then inst tsu fi fi -inst moreutils screen ncdu lsof htop proxytunnel pv curl wget sshfs netcat mosh bash-completion +inst moreutils screen ncdu lsof htop proxytunnel pv curl wget sshfs netcat mosh bash-completion rsync if [ $ARCH == 1 ]; then inst gopass else @@ -214,14 +214,22 @@ git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim vim +PluginInstall +qall # YouCompleteMe (vim plugin) -if [ $DEBIAN == 1 || $TERMUX == 1 ]; then - inst python-dev python3-dev +if [ $ARCH == 1 ] && [ $ADMIN == 1 ]; then + if [ $EXTRA == 1 ]; then + altInst vim-youcompleteme-git + else + altInst vim-youcompleteme-core-git + fi +else + if [ $DEBIAN == 1 || $TERMUX == 1 ]; then + inst python-dev python3-dev + fi + YCM_ARGS="" + if [ $TERMUX != 1 ]; then + YCM_ARGS="$YCM_ARGS --clang-completer --tern-completer" + fi + python $HOME/.vim/bundle/YouCompleteMe/install.py $YCM_ARGS fi -YCM_ARGS="" -if [ $TERMUX != 1 ]; then - YCM_ARGS="$YCM_ARGS --clang-completer --tern-completer" -fi -python $HOME/.vim/bundle/YouCompleteMe/install.py $YCM_ARGS # Common GUI diff --git a/scripts/install-wsl b/scripts/install-wsl new file mode 100755 index 0000000..e439a64 --- /dev/null +++ b/scripts/install-wsl @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +# Setups a WSL system the way I like it + +# Remember to use the alwsl script on GitHub to install Arch Linux on WSL +# Use github:cbucher/console as a console and github:mintty/wsltty as a shell +# (%LOCALAPPDATA%/wsltty/bin/wsl-bridge) to avoid arrow keys bypassing + +(cd /usr/share/i18n/charmaps/; sudo gunzip -k UTF8.gz) +echo "fr_FR.UTF-8 UTF-8" | sudo tee -a /etc/locale.gen +sudo locale-gen