Update translate

master3.3
Mike Hiretsky 12 years ago
parent db43317ca2
commit d2f9ff4837

@ -773,11 +773,11 @@ class Install(color_print):
# join templates # join templates
if self.clVars.Get('os_install_pxe') == 'on': if self.clVars.Get('os_install_pxe') == 'on':
self.startTask( self.startTask(
_("Configuring the PXE install"),progress=True) _("Configuring PXE install"),progress=True)
self.applyTemplatesFlash('/') self.applyTemplatesFlash('/')
else: else:
self.startTask( self.startTask(
_("Configuring the Flash install"),progress=True) _("Configuring Flash install"),progress=True)
self.applyTemplatesFlash(self.targetDistr.getDirectory()) self.applyTemplatesFlash(self.targetDistr.getDirectory())
self.endTask() self.endTask()
self.closeClTemplate() self.closeClTemplate()
@ -819,8 +819,8 @@ class Install(color_print):
if process('/bin/umount',mountDir).success(): if process('/bin/umount',mountDir).success():
break break
else: else:
self.printWARNING(_("Unable umount %s")%mountDir) self.printWARNING(_("Unable to umount %s")%mountDir)
try: try:
os.rmdir(mountDir) os.rmdir(mountDir)
except: except:
self.printWARNING(_("Unable remove directory %s")%mountDir) self.printWARNING(_("Unable to remove directory %s")%mountDir)

@ -162,7 +162,7 @@ class VariableOsInstallX11VideoDrv(VideoVariable):
if self.Get('cl_action') == 'system': if self.Get('cl_action') == 'system':
availDrvs = self.Get('os_install_x11_video_available') availDrvs = self.Get('os_install_x11_video_available')
if not value in availDrvs: if not value in availDrvs:
raise VariableError(_("Only drivers % are available")% raise VariableError(_("Only %s drivers are available")%
",".join(availDrvs)) ",".join(availDrvs))
else: else:
if not value in getInstalledVideo(prefix="/") and \ if not value in getInstalledVideo(prefix="/") and \
@ -189,7 +189,7 @@ class VariableOsInstallX11Composite(VideoVariable):
opt = ['--composite'] opt = ['--composite']
def init(self): def init(self):
self.help = _("set the composite") self.help = _("toggle composite")
self.label = _("Composite") self.label = _("Composite")
def get(self): def get(self):

@ -414,8 +414,7 @@ class VariableClAutopartitionDevice(AutopartitionHelper,Variable):
def check(self,valuelist): def check(self,valuelist):
if self.Get('cl_autopartition_set') == "on": if self.Get('cl_autopartition_set') == "on":
if not valuelist: if not valuelist:
raise VariableError(_("For autopartition, please select " raise VariableError(_("For autopartition, please select the device"))
"the install device"))
useDisks = self.Select('os_disk_parent', useDisks = self.Select('os_disk_parent',
where='os_disk_mount',ne='') where='os_disk_mount',ne='')
for value in valuelist: for value in valuelist:
@ -467,7 +466,7 @@ class VariableClAutopartitionScheme(AutopartitionHelper,Variable,AutoPartition):
def init(self): def init(self):
self.help = _("autopartition options") self.help = _("autopartition options")
self.label = _("Autopartion options") self.label = _("Autopartition options")
def choice(self): def choice(self):
return [ return [

@ -595,7 +595,7 @@ class LocationHelper:
""" """
if self.Get('cl_autopartition_set') == "on": if self.Get('cl_autopartition_set') == "on":
return \ return \
_("Locations are not available with autopartitioning") _("The layout is not available with autopartitioning")
return "" return ""
class VariableOsLocationData(LocationHelper,TableVariable): class VariableOsLocationData(LocationHelper,TableVariable):
@ -618,7 +618,7 @@ class VariableOsLocationData(LocationHelper,TableVariable):
"DIR directory. If set to 'none', the mount point will " "DIR directory. If set to 'none', the mount point will "
"not be moved. To create a bind mount point, you have " "not be moved. To create a bind mount point, you have "
"to specify the source directory as DISK") "to specify the source directory as DISK")
self.label = _("Locations") self.label = _("Layout")
def set(self,value): def set(self,value):
return sorted(value,key=lambda x:x and x[0]) return sorted(value,key=lambda x:x and x[0])
@ -883,11 +883,9 @@ class VariableOsLocationDest(LocationHelper,Variable):
if osInstallRootType == "flash": if osInstallRootType == "flash":
if filter(lambda x: x and x != '/', value): if filter(lambda x: x and x != '/', value):
raise VariableError( raise VariableError(
_("The Flash install is not supported for " _("Flash install does not support multipartition mode"))
"multipartition install"))
if filter(lambda x: x == "swap",value): if filter(lambda x: x == "swap",value):
raise VariableError(_("The Flash install is not supported " raise VariableError(_("Flash install does not support swap disks"))
"for swap disks"))
######################################## ########################################
# check install on member of RAID or LVM # check install on member of RAID or LVM
######################################## ########################################
@ -898,8 +896,7 @@ class VariableOsLocationDest(LocationHelper,Variable):
installTypes) installTypes)
if memberData: if memberData:
raise VariableError( raise VariableError(
_("Unable to use active {typepart} member {part} " _("Unable to use {part} partition used by active {typepart} for installation").format(
"for installation").format(
typepart=checkType.upper(), typepart=checkType.upper(),
part=memberData[0][0])) part=memberData[0][0]))
@ -964,7 +961,7 @@ class VariableOsLocationFormat(LocationHelper,Variable):
for dev,mp,fs in devMpFs: for dev,mp,fs in devMpFs:
if dev.startswith('/') and not dev.startswith('/dev/') and fs: if dev.startswith('/') and not dev.startswith('/dev/') and fs:
raise VariableError( raise VariableError(
_("Bind mount points does not use filesystem")) _("The bind mount point does not use filesystem"))
# check compatible fs for mount point only root dirs # check compatible fs for mount point only root dirs
if dev.startswith('/dev/') and mp and (mp.count('/') == 1 or if dev.startswith('/dev/') and mp and (mp.count('/') == 1 or
mp == '/var/calculate'): mp == '/var/calculate'):
@ -973,7 +970,7 @@ class VariableOsLocationFormat(LocationHelper,Variable):
raise VariableError( raise VariableError(
_("The filesystem for '%(mp)s' should not be '%(opt)s'") _("The filesystem for '%(mp)s' should not be '%(opt)s'")
%{'mp':mp, 'opt':fs}+" "+ %{'mp':mp, 'opt':fs}+" "+
_("for the {typedisk} install").format( _("for {typedisk} install").format(
typedisk=osInstallRootType)) typedisk=osInstallRootType))
if mp == "swap" and fs != "swap": if mp == "swap" and fs != "swap":
raise VariableError( raise VariableError(
@ -1033,7 +1030,7 @@ class VariableOsLocationPerformFormat(LocationHelper,Variable):
# partition use in current system # partition use in current system
if diskMount.get(dev,''): if diskMount.get(dev,''):
raise VariableError( raise VariableError(
_("{device} should, but cannot be formatted, as it is " _("{device} must but cannot be formatted, as it is "
"mounted to {mountpoint} on the current system").format( "mounted to {mountpoint} on the current system").format(
device=dev,mountpoint=diskMount.get(dev,''))) device=dev,mountpoint=diskMount.get(dev,'')))
if isMount(dev): if isMount(dev):
@ -1043,12 +1040,12 @@ class VariableOsLocationPerformFormat(LocationHelper,Variable):
# but user select non-format # but user select non-format
if not self.isTrue(isformat): if not self.isTrue(isformat):
raise VariableError( raise VariableError(
_("{device} should be formatted").format( _("{device} must be formatted").format(
device=dev)) device=dev))
if self.isTrue(isformat): if self.isTrue(isformat):
if not mp: if not mp:
raise VariableError( raise VariableError(
_("No need to format the unused device {dev}").format( _("No need to format unused device {dev}").format(
dev=dev)) dev=dev))
if fs in unavailFS: if fs in unavailFS:
raise VariableError( raise VariableError(
@ -1058,8 +1055,7 @@ class VariableOsLocationPerformFormat(LocationHelper,Variable):
_("Bind mount points should not be formatted")) _("Bind mount points should not be formatted"))
elif diskMount.get(dev,"") and isformat: elif diskMount.get(dev,"") and isformat:
raise VariableError( raise VariableError(
_("{device} cannot be formatted, as it is " _("{device} must but cannot be formatted, as it is mounted to {mountpoint} on the current system"
"mounted to {mountpoint} on the current system"
).format( ).format(
device=dev,mountpoint=diskMount.get(dev,''))) device=dev,mountpoint=diskMount.get(dev,'')))
elif isMount(dev): elif isMount(dev):
@ -1152,7 +1148,7 @@ class VariableClUuidSet(Variable):
Unavailable for flash installation Unavailable for flash installation
""" """
if self.Get('os_install_root_type') == 'flash': if self.Get('os_install_root_type') == 'flash':
return _("UUID using unavailable for Flash install") return _("Impossible to use UUID for Flash install")
############################################################# #############################################################
# Install disk parameters # Install disk parameters
@ -1488,7 +1484,7 @@ class VariableOsInstallMbr(LocationHelper,Variable):
if rootType == "flash": if rootType == "flash":
if len(value) > 1: if len(value) > 1:
raise VariableError( raise VariableError(
_("For the Flash install, you need only one disk")) _("For Flash install, you need only one disk"))
for mbrDisk in value: for mbrDisk in value:
if self.Get('cl_autopartition_set') == 'on': if self.Get('cl_autopartition_set') == 'on':
tableOnBootDisk = self.Get('cl_autopartition_table') tableOnBootDisk = self.Get('cl_autopartition_table')
@ -1497,12 +1493,11 @@ class VariableOsInstallMbr(LocationHelper,Variable):
where="os_device_dev",eq=mbrDisk,limit=1) where="os_device_dev",eq=mbrDisk,limit=1)
if not tableOnBootDisk: if not tableOnBootDisk:
raise VariableError( raise VariableError(
_("Disk '%s' need a partition table for the boot record")% _("Disk '%s' needs a partition table for the boot record")%
mbrDisk) mbrDisk)
if rootType == "flash": if rootType == "flash":
if tableOnBootDisk == "gpt": if tableOnBootDisk == "gpt":
raise VariableError(_("For the Flash install, you " raise VariableError(_("You need a disk with a dos table for Flash install"))
"need a disk with a dos table"))
if value: if value:
if self.Get('os_grub2_path'): if self.Get('os_grub2_path'):
self.checkForGrub2() self.checkForGrub2()
@ -1518,7 +1513,7 @@ class VariableOsInstallMbr(LocationHelper,Variable):
sort="DESC",limit=1) sort="DESC",limit=1)
if "lvm-raid" in grubDiskType: if "lvm-raid" in grubDiskType:
raise VariableError( raise VariableError(
_("Grub does not support booting from a RAID assembled from LVM") _("Grub does not support booting from a RAID assembled from a LVM")
+ ". " + + ". " +
_("Try to use a separate /boot partition")) _("Try to use a separate /boot partition"))
if grubDiskType.count("raid")>1: if grubDiskType.count("raid")>1:
@ -1539,8 +1534,7 @@ class VariableOsInstallMbr(LocationHelper,Variable):
sort="DESC",limit=1) sort="DESC",limit=1)
if "lvm" in bootDiskType or "raid" in bootDiskType: if "lvm" in bootDiskType or "raid" in bootDiskType:
raise ValueError( raise ValueError(
_("Legacy grub requires a separate /boot partition to " _("Legacy grub requires a separate /boot partition to support boot from a RAID or a LVM"))
"support boot from RAID or LVM"))
if bootDiskFormat in ("btrfs","nilfs2"): if bootDiskFormat in ("btrfs","nilfs2"):
raise ValueError( raise ValueError(
_("To support booting from %s, legacy grub needs a " _("To support booting from %s, legacy grub needs a "

@ -356,7 +356,7 @@ class VariableClImageArchMachine(Variable,DistroRepository):
def choice(self): def choice(self):
return [("",_("Not used"))]+\ return [("",_("Not used"))]+\
[("auto",_("Automatic"))] + \ [("auto",_("Auto"))] + \
[(x,x) for x in self.available_arch] [(x,x) for x in self.available_arch]
def humanReadable(self): def humanReadable(self):

@ -40,7 +40,7 @@ class VariableOsInstallKernelScheduler(Variable):
metavalue = "SCHEDULER" metavalue = "SCHEDULER"
def init(self): def init(self):
self.help = _("set the I/O scheduler") self.help = _("toggle the I/O scheduler")
self.label = _("I/O scheduler") self.label = _("I/O scheduler")
def get(self): def get(self):

@ -38,7 +38,7 @@ class LocaleVariable(ReadonlyVariable,Locale):
""" """
if self.Get('os_install_root_type') == 'flash': if self.Get('os_install_root_type') == 'flash':
return \ return \
_("Locale configuration unavailable for the Flash install") _("Locale configuration unavailable for Flash install")
return "" return ""
class VariableOsInstallLinguas(LocaleVariable): class VariableOsInstallLinguas(LocaleVariable):
@ -180,7 +180,7 @@ class VariableOsInstallClockTimezone(LocaleVariable):
def check(self,value): def check(self,value):
if not value or not path.isfile(path.join( if not value or not path.isfile(path.join(
"/usr/share/zoneinfo",value)): "/usr/share/zoneinfo",value)):
raise VariableError(_("the %s timezone is wrong")%value) raise VariableError(_("Wrong timezone %s")%value)
def generateComments(self,tzs): def generateComments(self,tzs):
""" """

@ -44,7 +44,7 @@ class NetHelper:
""" """
if self.Get('os_install_root_type') == 'flash': if self.Get('os_install_root_type') == 'flash':
return \ return \
_("Network configuration is unavailable for the Flash install") _("Network configuration is unavailable for Flash install")
if self.routing and not self.Select('os_install_net_interfaces', if self.routing and not self.Select('os_install_net_interfaces',
where='os_install_net_dhcp_set', where='os_install_net_dhcp_set',
eq='off',limit=1): eq='off',limit=1):
@ -666,7 +666,7 @@ class VariableOsInstallNetDns(VariableOsInstallNetDnsSearch):
def check(self,value): def check(self,value):
reIp = re.compile(ip.IP_ADDR) reIp = re.compile(ip.IP_ADDR)
if any(ifilterfalse(reIp.match,value.split(','))): if any(ifilterfalse(reIp.match,value.split(','))):
raise VariableError(_("Wrong IP addresses for DNS")) raise VariableError(_("Wrong IP address for DNS"))
def humanReadable(self): def humanReadable(self):
return self.Get() or (_("Get via DHCP") return self.Get() or (_("Get via DHCP")

@ -72,7 +72,7 @@ class VariableOsInstallScratch(Variable):
# scratch not use for falsh and multipartition # scratch not use for falsh and multipartition
if self.Get('os_install_root_type') == "flash": if self.Get('os_install_root_type') == "flash":
raise VariableError( raise VariableError(
_("The Flash install is not supported in the builder mode")) _("Flash install does not support the builder mode"))
if filter(lambda x: not x in ('/','swap'), if filter(lambda x: not x in ('/','swap'),
self.Get('os_install_disk_mount')): self.Get('os_install_disk_mount')):
raise VariableError( raise VariableError(
@ -84,7 +84,7 @@ class VariableOsInstallScratch(Variable):
Unavailable for flash installation Unavailable for flash installation
""" """
if self.Get('os_install_root_type') == 'flash': if self.Get('os_install_root_type') == 'flash':
return _("The Flash install is not supported in the builder mode") return _("Flash install does not support the builder mode")
class VariableOsFormatType(ReadonlyVariable): class VariableOsFormatType(ReadonlyVariable):
""" """
@ -121,7 +121,7 @@ class VariableClMigrateRootPwd(UserHelper,Variable):
untrusted = True untrusted = True
def init(self): def init(self):
self.help = _("to specify root password") self.help = _("specify the root password")
self.label = _("Root password") self.label = _("Root password")
def get(self): def get(self):
@ -154,7 +154,7 @@ class VariableClMigrateRootPwd(UserHelper,Variable):
def check(self,value): def check(self,value):
if not value: if not value:
raise PasswordError(_("Missed a password for user %s")%"root") raise PasswordError(_("Password for user %s missing")%"root")
class VariableClMigrateData(UserHelper,TableVariable): class VariableClMigrateData(UserHelper,TableVariable):
""" """
@ -263,7 +263,7 @@ class VariableClMigrateUserPwd(UserHelper,Variable):
for user,pwd in zip(self.Get('cl_migrate_user'),value): for user,pwd in zip(self.Get('cl_migrate_user'),value):
if not pwd: if not pwd:
raise PasswordError( raise PasswordError(
_("Missed a password for user %s")%user) _("Password for user %s missing")%user)
def set(self,value): def set(self,value):
""" """
@ -526,8 +526,8 @@ class VariableClLive(Variable):
opt = ['--live'] opt = ['--live']
def init(self): def init(self):
self.label = _("Configure only dynamic options") self.label = _("Configure dynamic options only")
self.help = _("configure only dynamic options") self.help = _("configure dynamic options only")
class VariableOsInstallPxe(ReadonlyVariable): class VariableOsInstallPxe(ReadonlyVariable):
""" """
@ -540,12 +540,11 @@ class VariableOsInstallPxe(ReadonlyVariable):
if value == "on": if value == "on":
if self.Get('os_linux_system') != "server": if self.Get('os_linux_system') != "server":
raise VariableError( raise VariableError(
_("The PXE install is available for Calculate Directory " _("PXE install is available for Calculate Directory Server only")+'.')
"Server only")+'.')
for pkg in ['net-misc/dhcp','net-ftp/tftp-hpa','net-fs/nfs-utils']: for pkg in ['net-misc/dhcp','net-ftp/tftp-hpa','net-fs/nfs-utils']:
if not isPkgInstalled(pkg): if not isPkgInstalled(pkg):
raise VariableError( raise VariableError(
_("For the PXE install, you need to install package %s") _("For PXE install, you need to install package %s")
%pkg) %pkg)
try: try:
config = cl_template.iniParser('/etc/calculate/calculate.env') config = cl_template.iniParser('/etc/calculate/calculate.env')
@ -555,8 +554,7 @@ class VariableOsInstallPxe(ReadonlyVariable):
except: except:
pass pass
raise VariableError( raise VariableError(
_("The PXE install is only available if the DHCP service has " _("PXE install is only available if the DHCP service has been configured first"))
"been configured first"))
class VariableOsInstallPxePath(Variable): class VariableOsInstallPxePath(Variable):
""" """
@ -567,5 +565,5 @@ class VariableOsInstallPxePath(Variable):
opt = ['--pxe-path'] opt = ['--pxe-path']
def init(self): def init(self):
self.label = _("Path for installation") self.label = _("Installation path")
self.help = _("path for the PXE install") self.help = _("path for PXE install")

Loading…
Cancel
Save