From bd98b8a308bfb8803e0abd62a912195bdc351880 Mon Sep 17 00:00:00 2001 From: Naman Sood Date: Mon, 16 Jan 2023 12:32:25 -0500 Subject: [PATCH] changes Signed-off-by: Naman Sood --- bin/studentcpyinto | 6 ++++-- bin/studentcpyoutof | 2 +- bin/studentenv | 2 +- bin/studentlatex | 2 +- bin/studentmnt | 2 +- fonts.conf | 23 +++++++++++++++++++++++ install.sh | 1 + plan | 1 + zprofile | 7 +++++++ zshrc | 16 ++++++++-------- 10 files changed, 48 insertions(+), 14 deletions(-) create mode 100644 fonts.conf create mode 100644 plan create mode 100644 zprofile diff --git a/bin/studentcpyinto b/bin/studentcpyinto index ce1cc21..00bc5d8 100755 --- a/bin/studentcpyinto +++ b/bin/studentcpyinto @@ -1,3 +1,5 @@ -#!/bin/sh +#!/usr/bin/env bash source ~/bin/studentvars -scp $1 $UW_SERVER:$2 +allargsexceptlast=${@:1:$(($#-1))} +last=${!#} +scp $allargsexceptlast $UW_SERVER:$last diff --git a/bin/studentcpyoutof b/bin/studentcpyoutof index 066bef7..bb0912b 100755 --- a/bin/studentcpyoutof +++ b/bin/studentcpyoutof @@ -1,3 +1,3 @@ -#!/bin/sh +#!/usr/bin/env bash source ~/bin/studentvars scp -r $UW_SERVER:$1 $2 diff --git a/bin/studentenv b/bin/studentenv index 84478dc..3b9eb6a 100755 --- a/bin/studentenv +++ b/bin/studentenv @@ -1,4 +1,4 @@ -#!/usr/bin/zsh +#!/usr/bin/env bash source ~/bin/studentvars ssh $UW_SERVER -t 'zsh' diff --git a/bin/studentlatex b/bin/studentlatex index 1fc7ae7..9895814 100755 --- a/bin/studentlatex +++ b/bin/studentlatex @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash if [ $# -lt 1 ]; then echo "Usage: $0 [other required files...]" diff --git a/bin/studentmnt b/bin/studentmnt index 8a6c15d..963d87f 100755 --- a/bin/studentmnt +++ b/bin/studentmnt @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash source ~/bin/studentvars mkdir -p ~/studentenv sshfs $UW_SERVER: ~/studentenv diff --git a/fonts.conf b/fonts.conf new file mode 100644 index 0000000..87031a2 --- /dev/null +++ b/fonts.conf @@ -0,0 +1,23 @@ + + + + + serif + + Twemoji + + + + sans-serif + + Twemoji + + + + monospace + + Twemoji + + + + diff --git a/install.sh b/install.sh index 77288b0..ab4b552 100755 --- a/install.sh +++ b/install.sh @@ -4,6 +4,7 @@ set -euo pipefail DOTFILES=( vimrc + zprofile zshrc plan ) diff --git a/plan b/plan new file mode 100644 index 0000000..b1147f0 --- /dev/null +++ b/plan @@ -0,0 +1 @@ +idk man tbh diff --git a/zprofile b/zprofile new file mode 100644 index 0000000..e62e211 --- /dev/null +++ b/zprofile @@ -0,0 +1,7 @@ +# fix for WSL not starting ssh-agent on boot +if [ -z "$SSH_AUTH_SOCK" ] ; then + eval `ssh-agent -s` + grep -slR PRIVATE ~/.ssh/ | xargs ssh-add +fi + +export TENDS_TO=42 diff --git a/zshrc b/zshrc index 302425c..8dac141 100644 --- a/zshrc +++ b/zshrc @@ -1,7 +1,6 @@ # PATH changes are in .zshenv alias sudo='sudo --preserve-env=PATH env ' alias lntexheader='ln -s ~/coursenotes/nsdheader.sty $(pwd)' -EDITOR=vim # Path to your oh-my-zsh installation. export ZSH="$HOME/.oh-my-zsh" @@ -105,12 +104,6 @@ source $ZSH/oh-my-zsh.sh [[ ! -r /home/nsood/.opam/opam-init/init.zsh ]] || source /home/nsood/.opam/opam-init/init.zsh > /dev/null 2> /dev/null -# fix for WSL not starting ssh-agent on boot -if [ -z "$SSH_AUTH_SOCK" ] ; then - eval `ssh-agent -s` - grep -slR PRIVATE ~/.ssh/ | xargs ssh-add -fi - exp() { cd "$@" && ls } @@ -119,6 +112,13 @@ cdmk() { mkdir -p "$@" && cd "$@" } -if which gvim &>/dev/null && ! which vim echo &>/dev/null; then +if which gvim &>/dev/null && ! which vim &>/dev/null; then alias vim='gvim -v' + export EDITOR='gvim -v' +else + export EDITOR=vim fi + +alias ':q'=exit +alias open=xdg-open +alias neofetch=hyfetch