forked from tylda-public/helpers
make neomitt setup a function
This commit is contained in:
25
add_user.sh
25
add_user.sh
@@ -18,23 +18,16 @@ zfs create -o mountpoint=/home/$LOGIN -o quota=200M tank/ROOT/homes/$LOGIN
|
|||||||
chown $LOGIN:$LOGIN /home/$LOGIN
|
chown $LOGIN:$LOGIN /home/$LOGIN
|
||||||
cat "export EDITOR=nvim" >> /home/$LOGIN/.ashrc
|
cat "export EDITOR=nvim" >> /home/$LOGIN/.ashrc
|
||||||
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Inbox/cur
|
setup_neomutt () {
|
||||||
mkdir -p /home/$LOGIN/Maildir/Inbox/new
|
for dir in "Inbox" "Sent" "Drafts" "Trash"; do
|
||||||
mkdir -p /home/$LOGIN/Maildir/Inbox/tmp
|
for subdir in "cur" "new" "tmp"; do
|
||||||
|
# mkdir -p /home/"$LOGIN"/Maildir/$dir/$subdir
|
||||||
|
echo "$dir/$subdir"
|
||||||
|
done
|
||||||
|
done
|
||||||
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Sent/cur
|
chmod -R 0700 /home/"$LOGIN"/Maildir
|
||||||
mkdir -p /home/$LOGIN/Maildir/Sent/new
|
}
|
||||||
mkdir -p /home/$LOGIN/Maildir/Sent/tmp
|
|
||||||
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Drafts/cur
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Drafts/new
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Drafts/tmp
|
|
||||||
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Trash/cur
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Trash/new
|
|
||||||
mkdir -p /home/$LOGIN/Maildir/Trash/tmp
|
|
||||||
|
|
||||||
chmod -R 0700 /home/$LOGIN/Maildir
|
|
||||||
|
|
||||||
cp -r /root/helpers/public_html /home/$LOGIN/
|
cp -r /root/helpers/public_html /home/$LOGIN/
|
||||||
sed -i "s/<<USER>>/$LOGIN/g" /home/$LOGIN/public_html/index.php
|
sed -i "s/<<USER>>/$LOGIN/g" /home/$LOGIN/public_html/index.php
|
||||||
|
|||||||
Reference in New Issue
Block a user