Initial Commit of stdheader for 42lausanne

This commit is contained in:
Baco
2021-10-23 15:16:30 +02:00
commit 9ef0496968
5 changed files with 247 additions and 0 deletions

26
set_header.sh Executable file
View File

@@ -0,0 +1,26 @@
#!/bin/bash
# ./set_header.sh
# Set variables
if [ ! -z "$USER" ]
then
echo 'export USER=`/usr/bin/whoami`' >> ~/.zshrc
fi
if [ ! -z "$GROUP" ]
then
echo 'export GROUP=`/usr/bin/id -gn ${USER}`' >> ~/.zshrc
fi
if [ ! -z "$MAIL" ]
then
echo 'export MAIL="${USER}@student.42lausanne.ch"' >> ~/.zshrc
fi
test -d ~/.vim/plugin || mkdir -p ~/.vim/plugin
# Add stdheader to vim plugins
cp vim/stdheader.vim ~/.vim/plugin/
source ~/.zshrc