Inital commit
This commit is contained in:
21
Tool-Gparted.sh
Normal file
21
Tool-Gparted.sh
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
#Check if config is in current directory
|
||||
if [[ ! -f Locations.conf ]];then
|
||||
echo "Location config not found, Please got to the Project directory"
|
||||
exit 10
|
||||
fi
|
||||
|
||||
source Locations.conf
|
||||
WorkDir=/opt/TMPLDSIDWD
|
||||
TargetDir="$WWWStore/Tools/Gparted"
|
||||
[ -d "$WorkDir" ] || mkdir -p "$WorkDir"
|
||||
mkdir -p $TargetDir
|
||||
#Set architecture
|
||||
GPArch=amd64 # can be amd64 i686-pae or i686
|
||||
|
||||
#Get gparted Version
|
||||
GPVer=$(wget -q -O- https://gparted.org/download.php |grep "Download gparted-live-" | grep "amd64.iso" | sed -e 's/<[^>]*>//g' -e 's/Download gparted-live-//g' -e 's/-amd64.iso//g' -e 's/ //g')
|
||||
#Download amd64 version
|
||||
wget -O "$WorkDir"/Gparted.zip https://sourceforge.net/projects/gparted/files/gparted-live-stable/$GPVer/gparted-live-$GPVer-$GPArch.zip/download
|
||||
unzip -j "$WorkDir"/Gparted.zip live/vmlinuz live/initrd.img live/filesystem.squashfs live/GParted-Live-Version -d $TargetDir
|
||||
rm -rf "$WorkDir"
|
||||
Reference in New Issue
Block a user