new scripts

This commit is contained in:
NaiJi ✨ 2023-03-04 00:30:51 +04:00
parent 1f2386bf95
commit f7e5fd5e00
2 changed files with 21 additions and 0 deletions

8
createswap.sh Normal file
View File

@ -0,0 +1,8 @@
#!/bin/bash
echo " -- Create /swapfile"
sudo dd if=/dev/zero of=/swapfile bs=1G count=20
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo "-- Activated"

13
lsblkmounter.sh Normal file
View File

@ -0,0 +1,13 @@
#!/bin/bash
lsblk
echo ""
if [ ! -z $1 ]
then
mkdir -p ~/Mounts
mkdir -p ~/Mounts/$1
sudo mount /dev/$1 ~/Mounts/$1
else
echo ""
echo "Input 'NAME' to mount in ~/Mounts/'NAME'"
fi