All pastes #1639707 Raw Edit

Stuff

public text v1 · immutable
#1639707 ·published 2009-10-23 10:22 UTC
rendered paste body
# MyDefrag v4.0 default script: Move To End Of Disk
#
# This is an example script.

Title('Move To End Of Disk')
Description('
Move all the files and directories to the end of the selected disk(s).
')


WriteLogfile("MyDefrag.log","LogHeader")

# Exclude the files that you do NOT want to move to the end of the disk. */
ExcludeFiles(All and not(FileName("*.avi")))

# Analyze the volume and move the not-excluded files to the end of the disk.
VolumeSelect
  CommandlineVolumes()
VolumeActions

  AppendLogfile("MyDefrag.log","LogBefore")

  /* Dirty trick to move all the files (that are not excluded by the ExcludeFiles
     before) to the end of the disk. Files may get fragmented. */
  MakeGap(PercentageOfVolume(100))

  AppendLogfile("MyDefrag.log","LogAfter")

VolumeEnd