64 |
if [ "$clonType" = "i686" ];then |
if [ "$clonType" = "i686" ];then |
65 |
clonType="$clonType"-pae |
clonType="$clonType"-pae |
66 |
fi |
fi |
67 |
clonIso="http://sourceforge.net/projects/clonezilla/files/clonezilla_live_stable/OldFiles/"$clonVersion"/clonezilla-live-"$clonVersion"-"$clonType".iso/download" |
clonIso="http://downloads.sourceforge.net/project/clonezilla/clonezilla_live_stable/OldFiles/"$clonVersion"/clonezilla-live-"$clonVersion"-"$clonType".iso?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fclonezilla%2Ffiles%2Fclonezilla_live_stable%2FOldFiles%2F"$clonVersion"%2F" |
68 |
downloadClonezillaLive |
downloadClonezillaLive |
69 |
done |
done |
70 |
else |
else |
72 |
if [ "$clonType" = "i686" ];then |
if [ "$clonType" = "i686" ];then |
73 |
clonType="$clonType"-pae |
clonType="$clonType"-pae |
74 |
fi |
fi |
75 |
clonIso="http://sourceforge.net/projects/clonezilla/files/clonezilla_live_stable/OldFiles/"$clonVersion"/clonezilla-live-"$clonVersion"-"$clonType".iso/download" |
clonIso="http://downloads.sourceforge.net/project/clonezilla/clonezilla_live_stable/OldFiles/"$clonVersion"/clonezilla-live-"$clonVersion"-"$clonType".iso?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fclonezilla%2Ffiles%2Fclonezilla_live_stable%2FOldFiles%2F"$clonVersion"%2F" |
76 |
downloadClonezillaLive |
downloadClonezillaLive |
77 |
fi |
fi |
78 |
|
|
190 |
|
|
191 |
# Check if we have to go to OldFiles |
# Check if we have to go to OldFiles |
192 |
echo "Checking file availability..." |
echo "Checking file availability..." |
193 |
oldFiles="$(curl -IL "$clonIso" | grep '301 Moved Permanently')" |
oldFiles="$(curl -IL "$clonIso" | grep 'Location: http://')" |
194 |
if [ -n "$oldFiles" ];then |
if [ -z "$oldFiles" ];then |
195 |
# go to stable |
# go to stable |
196 |
clonIso="$(echo "$clonIso" | sed 's{OldFiles/{{')" |
clonIso="$(echo "$clonIso" | sed 's{OldFiles/{{' | sed 's{OldFiles%2F{{')" |
197 |
echo "This is Clonezilla Live Stable!!!" |
echo ">>>>>> This is Clonezilla Live Stable!!!" |
198 |
else |
else |
199 |
echo "This is an older Clonezilla Live version!!!" |
echo ">>>>>> This is an older Clonezilla Live version!!!" |
200 |
fi |
fi |
201 |
|
|
202 |
# Download file |
# Download file |
657 |
downloadIsoFiles $ARCH |
downloadIsoFiles $ARCH |
658 |
exit |
exit |
659 |
fi |
fi |
660 |
# chack auto mode |
# check auto mode |
661 |
if [ -n "$auto" ];then |
if [ -n "$auto" ];then |
662 |
if [ -z "$usingProfile" ];then |
if [ -z "$usingProfile" ];then |
663 |
echo ' Error: Parameter -a used without -p' |
echo ' Error: Parameter -a used without -p' |
702 |
# |
# |
703 |
# Is this correct? (y/[n]): " |
# Is this correct? (y/[n]): " |
704 |
|
|
705 |
if [ -n "$auto" ]; then |
if [ -n "$auto" ]; then |
706 |
ans=y |
ans=y |
707 |
else |
else |
708 |
echo -n "Current settings: |
echo -n "Current settings: |
709 |
System Rescue CD: $sysCD |
System Rescue CD: $sysCD |
710 |
Clonezilla Live CD: $cloneCD |
Clonezilla Live CD: $cloneCD |
711 |
isolinux.cfg to use: $cfgFile |
isolinux.cfg to use: $cfgFile |
712 |
script to execute: $exScript |
script to execute: $exScript |
713 |
|
|
714 |
Is this correct? (y/[n]): " |
Is this correct? (y/[n]): " |
715 |
|
|
716 |
read ans |
read ans |
717 |
fi |
fi |
718 |
if [ "$ans" = "n" ] || [ "$ans" = "N" ] || [ "$ans" = "" ];then |
if [ "$ans" = "n" ] || [ "$ans" = "N" ] || [ "$ans" = "" ];then |
719 |
sysCD='' |
sysCD='' |
720 |
cloneCD='' |
cloneCD='' |
758 |
createTempFolders |
createTempFolders |
759 |
|
|
760 |
echo -n "Mounting ISO files... " |
echo -n "Mounting ISO files... " |
761 |
mount "$sysCD" "$SAVE_DIR"/tmp/syscd -o loop || errorMount ' Error mounting "System Rescue CD" file' |
mount "$sysCD" "$SAVE_DIR"/tmp/syscd -o ro,loop || errorMount ' Error mounting "System Rescue CD" file' |
762 |
mount "$cloneCD" "$SAVE_DIR"/tmp/clonecd -o loop || errorMount ' Error mounting Clonezilla" file' |
mount "$cloneCD" "$SAVE_DIR"/tmp/clonecd -o ro,loop || errorMount ' Error mounting Clonezilla" file' |
763 |
echo 'done' |
echo 'done' |
764 |
echo -n "Copying files... " |
echo -n "Copying files... " |
765 |
cp -RL "$SAVE_DIR"/tmp/syscd/* "$SAVE_DIR"/tmp/clonezilla-sysresccd |
cp -RL "$SAVE_DIR"/tmp/syscd/* "$SAVE_DIR"/tmp/clonezilla-sysresccd |