/[clonezilla-sysresccd]/trunk/create-clonezilla-sysresccd/create-clonezilla-sysresccd.sh
ViewVC logotype

Diff of /trunk/create-clonezilla-sysresccd/create-clonezilla-sysresccd.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 187 by sng, Tue Aug 21 13:20:56 2012 UTC revision 190 by sng, Sun Aug 26 14:25:43 2012 UTC
# Line 64  if [ "$1" = "all" ] || [ -z "$1" ];then Line 64  if [ "$1" = "all" ] || [ -z "$1" ];then
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
# Line 72  else Line 72  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    
# Line 190  fi Line 190  fi
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
# Line 657  else Line 657  else
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'
# Line 702  if [ $onlyBurnISO -eq 0 ];then Line 702  if [ $onlyBurnISO -eq 0 ];then
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=''
# Line 758  Is this correct? (y/[n]): " Line 758  Is this correct? (y/[n]): "
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

Legend:
Removed from v.187  
changed lines
  Added in v.190

webmaster@linux.gr
ViewVC Help
Powered by ViewVC 1.1.26