Add omz installs cript
This commit is contained in:
parent
086179c21a
commit
f696949031
5 changed files with 36 additions and 6 deletions
10
.config/mpv/scripts/paste.lua
Normal file
10
.config/mpv/scripts/paste.lua
Normal file
|
@ -0,0 +1,10 @@
|
|||
mp = require 'mp'
|
||||
function paste()
|
||||
local pasted = mp.command_native{
|
||||
name = 'subprocess',
|
||||
args = 'wl-paste',
|
||||
capture_stdout = true,
|
||||
}
|
||||
mp.commandv('loadfile', pasted.stdout:match('^%s*(.-)%s*$'))
|
||||
end
|
||||
mp.add_key_binding('Ctrl+v', 'paste', paste)
|
|
@ -1 +0,0 @@
|
|||
Subproject commit c3d4e576c9c86eac62884bd47c01f6faed043fc5
|
|
@ -1 +0,0 @@
|
|||
Subproject commit e0165eaa730dd0fa321a6a6de74f092fe87630b0
|
26
scripts/install-omz.sh
Executable file
26
scripts/install-omz.sh
Executable file
|
@ -0,0 +1,26 @@
|
|||
#!/bin/env bash
|
||||
|
||||
# Check if OMZ exists. If not, complain.
|
||||
if [ ! -d "$HOME/.oh-my-zsh" ]; then
|
||||
echo 'Installing Oh My Zsh (0/2)...'
|
||||
OLD_PWD=$(pwd)
|
||||
cd $HOME
|
||||
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh) --keep-zshrc --unattended"
|
||||
cd $OLD_PWD
|
||||
_S=$(awk -F: -v user="$USER" '$1 == user {print $NF}' /etc/passwd)
|
||||
if [ "$_S" != "/bin/zsh" ] && [ "$_S" != "/usr/bin/zsh" ]; then
|
||||
echo 'Changing shell to Zsh...'
|
||||
sudo chsh -s "/bin/zsh" $USER
|
||||
fi
|
||||
echo 'Oh My Zsh installed.'
|
||||
fi
|
||||
|
||||
# Install syntax highlighting
|
||||
echo 'Installing syntax highlighting (1/2)...'
|
||||
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
|
||||
|
||||
# Install autosuggestions
|
||||
echo 'Installing auto-suggestions (2/2)...'
|
||||
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
|
||||
|
||||
echo 'Done.
|
|
@ -1,4 +0,0 @@
|
|||
#!/bin/env python3
|
||||
import argparse
|
||||
import subprocess
|
||||
|
Loading…
Reference in a new issue