diff options
author | Florent Villard <warly@mandriva.com> | 2003-10-20 10:51:59 +0000 |
---|---|---|
committer | Florent Villard <warly@mandriva.com> | 2003-10-20 10:51:59 +0000 |
commit | 306951e28791b261f894a8b71255b4c45d105661 (patch) | |
tree | 9fa88f156c8a6fa200986dc52b42ab43047e81f6 /time_wizard | |
parent | eacbbd06a147d56f4edfaf008cc667b55577b3be (diff) | |
download | drakwizard-306951e28791b261f894a8b71255b4c45d105661.tar drakwizard-306951e28791b261f894a8b71255b4c45d105661.tar.gz drakwizard-306951e28791b261f894a8b71255b4c45d105661.tar.bz2 drakwizard-306951e28791b261f894a8b71255b4c45d105661.tar.xz drakwizard-306951e28791b261f894a8b71255b4c45d105661.zip |
change copyright
remove old xml related files
Diffstat (limited to 'time_wizard')
-rw-r--r-- | time_wizard/scripts/NTPConf.pm | 70 | ||||
-rwxr-xr-x | time_wizard/scripts/compute_liste.sh | 36 | ||||
-rw-r--r-- | time_wizard/time.wiz | 647 |
3 files changed, 0 insertions, 753 deletions
diff --git a/time_wizard/scripts/NTPConf.pm b/time_wizard/scripts/NTPConf.pm deleted file mode 100644 index efcc838d..00000000 --- a/time_wizard/scripts/NTPConf.pm +++ /dev/null @@ -1,70 +0,0 @@ -#!/usr/bin/perl - -# NTP Config Parser - -# Copyright (C) 2002 MandrakeSoft Arnaud Desmons <adesmons@mandrakesoft.com> -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2, or (at your option) -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - -package NTPConf; -require "__WIZ_HOME__/common/scripts/Vareqval.pm"; -use MDK::Common; -use strict; -use standalone; - -sub chooser4 { - if ($ENV{chooser4} eq "save_quit") { - do_it(); - return 1; - } - 2; -} - -sub test { - system("/usr/sbin/ntpdate -q $ENV{server1} $ENV{server2}"); - if (!($? >> 8)) { - do_it(); - return 1; - } - 2; -} - -sub do_it { - my $file = "/etc/sysconfig/clock"; - MDK::Common::cp_af($file, $file.".orig"); - open(NEW, "> $file") or die "can not open $file: $!"; - print NEW "UTC=true\n"; - print NEW "ZONE=$ENV{wiz_timezone}\n"; - print NEW "ARC=false\n"; - close NEW or die "can not close $file: $!"; - MDK::Common::cp_af("/usr/share/zoneinfo/$ENV{wiz_timezone}", "/etc/localtime"); - -f "/etc/ntp/step-tickers" and MDK::Common::cp_af("/etc/ntp/step-tickers", "/etc/ntp/step-tickers.orig"); - open(NEW, "> /etc/ntp/step-tickers") or die "can not open /etc/ntp/step-tickers: $!"; - print NEW $ENV{server1}."\n"; - print NEW $ENV{server2}."\n"; - close NEW or die "can not close /etc/ntp/step-tickers: $!"; - substInFile { s/(# server clock.via.net)/$1\nserver $ENV{server1}/ } '/etc/ntp.conf' if -f '/etc/ntp.conf'; - standalone::explanations("Wrote /etc/ntp/step-tickers, starting services"); - my @services = qw(crond atd ntpd); - foreach (@services) { - system("/etc/rc.d/init.d/$_ stop"); - } - foreach (reverse @services) { - system("/etc/rc.d/init.d/$_ start"); - } - system("/sbin/hwclock --systohc --utc"); - 10; -} -1; diff --git a/time_wizard/scripts/compute_liste.sh b/time_wizard/scripts/compute_liste.sh deleted file mode 100755 index 287808fb..00000000 --- a/time_wizard/scripts/compute_liste.sh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/bash -# -# Wizard -# -# Copyright (C) 2000 Mandrakesoft. -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License -# as published by the Free Software Foundation; either version 2 -# of the License, or (at your option) any later version. -# See file LICENSE for further informations on licensing terms. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -# -# Authors: Jerome Dumonteil, Maurizio De Cecco, Enzo Maggi -# icons: Helene Durosini <ln@mandrakesoft.com> -# <corporate@mandrakesoft.com> http://www.mandrakesoft.com - -# script for wizard time configuration -# -# echo on stdout liste & description (same) of timezone - -# zoneinfo directory probably exists, but -[ -d /usr/share/zoneinfo ] || exit 1 - -echo_debug "timezone list" - -cd /usr/share/zoneinfo && find [A-Z]* -type f | sort - diff --git a/time_wizard/time.wiz b/time_wizard/time.wiz deleted file mode 100644 index ac746ab2..00000000 --- a/time_wizard/time.wiz +++ /dev/null @@ -1,647 +0,0 @@ -<?xml version="1.0"?> - - -<Wizard - name="general" - libScript="__WIZ_HOME__/common/scripts/functions.sh" - wizardTitle="Time wizard" - imagePosition="top" - defaultImage="__WIZ_HOME__/time_wizard/images/Time.png" - perlModule="__WIZ_HOME__/time_wizard/scripts/NTPConf.pm" - rpm="ntp" - summaryFunc="do_it" -> - - <Variable - name="chooser1" - shellVariable="chooser1" - > - </Variable> - - <Variable - name="varserver1" - shellVariable="server1" - > - </Variable> - - - <Variable - name="varserver2" - shellVariable="server2" - > - </Variable> - - - <Variable - name="chooser4" - shellVariable="chooser4" - > - </Variable> - - <Variable - name="wiz_timezone" - shellVariable="wiz_timezone" - > - </Variable> - - <Variable - name="wiz_time_ok" - shellVariable="wiz_time_ok" - defaultValue="ok" - > - </Variable> - - <Page - helpURL="file:/usr/share/doc/mandrake/${LANG}/ref.html/wiz-time.html" - name="welcome" - executionLevel="NORMAL" - nextFinish="false" - canBack="true" - canCancel="true" - > - - <Info - helpText="This wizard will help you to set the time of your server synchronized with an external time server." - > - </Info> - - <Info - helpText="Thus your server will be the local time server for your network." - > - </Info> - - <Info - helpText="press next to begin, or cancel to leave this wizard" - > - </Info> - </Page> - - <Page - helpURL="file:/usr/share/doc/mandrake/${LANG}/ref.html/wiz-time.html" - name="choose_server" - executionLevel="NORMAL" - nextFinish="false" - canBack="true" - canCancel="true" - > - - <Info - helpText="Time Servers" - > - </Info> - - - <Info - helpText="Select a primary and secondary server from the list." - > - </Info> - - <Info - helpText="(please, choose servers in your geographical area)" - > - </Info> - - - <Chooser - name="chooserserver1" - variableName="varserver1" - helpText="Primary Time Server:" - editable="true" - > - <Option - value="bernina.ethz.ch" - description="Swiss Fed. Inst. of Technology" - > - </Option> - - <Option - value="clock.nc.fukuoka-u.ac.jp" - description="Fukuoka university, Fukuoka, Japan" - > - </Option> - - <Option - value="clock.psu.edu" - description="Penn State University, University Park, PA" - > - </Option> - - <Option - value="clock.tricity.wsu.edu" - description="Washington State University Tri-Cities, Richland, Wa" - > - </Option> - - <Option - value="constellation.ecn.uoknor.edu" - description="University of Oklahoma, Norman, Oklahoma, USA" - > - </Option> - - <Option - value="fartein.ifi.uio.no" - description="University of Oslo, Norway" - > - </Option> - - <Option - value="ntp.adelaide.edu.au" - description="University of Adelaide, South Australia" - > - </Option> - - <Option - value="ntp.cs.strath.ac.uk" - description="Dept. Computer Science, Strathclyde University, Glasgow, Scotland" - > - </Option> - - <Option - value="ntp.shim.org" - description="Singapore" - > - </Option> - - <Option - value="ntp.tmc.edu" - description="Baylor College of Medicine, Houston, Tx" - > - </Option> - - <Option - value="ntp1.cmc.ec.gc.ca" - description="Canadian Meteorological Centre, Dorval, Quebec, Canada" - > - </Option> - - <Option - value="ntp1.cs.wisc.edu" - description="Computer Science Department, University of Wisconsin-Madison" - > - </Option> - - <Option - value="ntp2a.mcc.ac.uk" - description="University of Manchester, Manchester, England" - > - </Option> - - <Option - value="sign.chg.ru" - description="Scientific Center in Chernogolovka, Moscow region, Russia" - > - </Option> - - <Option - value="salmon.maths.tcd.ie" - description="Trinity College, Dublin, Ireland" - > - </Option> - - <Option - value="slug.ctv.es" - description="Altea (Alicante/SPAIN)" - > - </Option> - - <Option - value="time.nrc.ca" - description="National Research Council of Canada, Ottawa, Ontario, Canada" - > - </Option> - - <Option - value="time.nuri.net" - description="Inet, Inc., Seoul, Korea" - > - </Option> - - <Option - value="tock.cs.unlv.edu" - description="UNLV College of Engineering, Las Vegas, NV" - > - </Option> - - <Option - value="timelord.uregina.ca" - description="University of Regina, Regina, Saskatchewan, Canada" - > - </Option> - - <Option - value="bitsy.mit.edu" - description="MIT Information Systems, Cambridge, MA" - > - </Option> - - <Option - value="lock.cuhk.edu.hk" - description="The Chinese University of Hong Kong" - > - </Option> - - <Option - value="ntp.univ-lyon1.fr" - description="CISM, Lyon, France" - > - </Option> - - <Option - value="ntp.laas.fr" - description="LAAS/CNRS, Toulouse, France" - > - </Option> - - <Option - value="ntp.unilim.fr" - description="SCI, Universite de Limoges, France" - > - </Option> - - <Option - value="ntp2.unicaen.fr" - description="CRIUC, Universite de Caen, France" - > - </Option> - - <Option - value="ntp.u-psud.fr" - description="CRI, Campus d'Orsay, Universite Paris Sud, France" - > - </Option> - - <Option - value="ntp.loria.fr" - description="Loria, Nancy, France" - > - </Option> - </Chooser> - - <Chooser - name="chooserserver2" - variableName="varserver2" - helpText="Secondary Time Server:" - helpFontName="Default" - helpFontStyle="plain" - helpFontSize="12" - editable="true" - > - - <Option - value="bernina.ethz.ch" - description="Swiss Fed. Inst. of Technology" - > - </Option> - - <Option - value="clock.nc.fukuoka-u.ac.jp" - description="Fukuoka university, Fukuoka, Japan" - > - </Option> - - <Option - value="clock.psu.edu" - description="Penn State University, University Park, PA" - > - </Option> - - <Option - value="clock.tricity.wsu.edu" - description="Washington State University Tri-Cities, Richland, Wa" - > - </Option> - - <Option - value="constellation.ecn.uoknor.edu" - description="University of Oklahoma, Norman, Oklahoma, USA" - > - </Option> - - <Option - value="fartein.ifi.uio.no" - description="University of Oslo, Norway" - > - </Option> - - <Option - value="ntp.adelaide.edu.au" - description="University of Adelaide, South Australia" - > - </Option> - - <Option - value="ntp.cs.strath.ac.uk" - description="Dept. Computer Science, Strathclyde University, Glasgow, Scotland" - > - </Option> - - <Option - value="ntp.shim.org" - description="Singapore" - > - </Option> - - <Option - value="ntp.tmc.edu" - description="Baylor College of Medicine, Houston, Tx" - > - </Option> - - <Option - value="ntp1.cmc.ec.gc.ca" - description="Canadian Meteorological Centre, Dorval, Quebec, Canada" - > - </Option> - - <Option - value="ntp1.cs.wisc.edu" - description="Computer Science Department, University of Wisconsin-Madison" - > - </Option> - - <Option - value="ntp2a.mcc.ac.uk" - description="University of Manchester, Manchester, England" - > - </Option> - - <Option - value="sign.chg.ru" - description="Scientific Center in Chernogolovka, Moscow region, Russia" - > - </Option> - - <Option - value="salmon.maths.tcd.ie" - description="Trinity College, Dublin, Ireland" - > - </Option> - - <Option - value="slug.ctv.es" - description="Altea (Alicante/SPAIN)" - > - </Option> - - <Option - value="time.nrc.ca" - description="National Research Council of Canada, Ottawa, Ontario, Canada" - > - </Option> - - <Option - value="time.nuri.net" - description="Inet, Inc., Seoul, Korea" - > - </Option> - - <Option - value="tock.cs.unlv.edu" - description="UNLV College of Engineering, Las Vegas, NV" - > - </Option> - - <Option - value="timelord.uregina.ca" - description="University of Regina, Regina, Saskatchewan, Canada" - > - </Option> - - <Option - value="bitsy.mit.edu" - description="MIT Information Systems, Cambridge, MA" - > - </Option> - - <Option - value="lock.cuhk.edu.hk" - description="The Chinese University of Hong Kong" - > - </Option> - - <Option - value="ntp.univ-lyon1.fr" - description="CISM, Lyon, France" - > - </Option> - - <Option - value="ntp.laas.fr" - description="LAAS/CNRS, Toulouse, France" - > - </Option> - - <Option - value="ntp.unilim.fr" - description="SCI, Universite de Limoges, France" - > - </Option> - - <Option - value="ntp2.unicaen.fr" - description="CRIUC, Universite de Caen, France" - > - </Option> - - <Option - value="ntp.u-psud.fr" - description="CRI, Campus d'Orsay, Universite Paris Sud, France" - > - </Option> - - <Option - value="ntp.loria.fr" - description="Loria, Nancy, France" - > - </Option> - <Option - value="ntp.u-psud.fr" - description="CRI, Campus d'Orsay, Universite Paris Sud, France" - > - </Option> - - <Option - value="ntp.loria.fr" - description="Loria, Nancy, France" - > - </Option> - - </Chooser> - - <Chooser - name="chooserwiz_timezone" - variableName="wiz_timezone" - defaultOptionScript="get_var wiz_timezone" - fillScript="__WIZ_HOME__/time_wizard/scripts/compute_liste.sh" - helpText="Choose a time zone:" - editable="false" - > - </Chooser> - </Page> - - <Page - helpURL="file:/usr/share/doc/mandrake/${LANG}/ref.html/wiz-time.html" - name="test_server" - func="test" - executionLevel="NORMAL" - nextFinish="false" - canBack="true" - canCancel="true" - > - - <Target - targetName="server_not_responding" - jumpIndex="2" - > - </Target> - - <Target - targetName="ciao" - jumpIndex="1" - > - </Target> - - <Info - helpText="Testing the time servers availability" - > - </Info> - - - <Info - helpText="If the time server is not immediately available (network or other reason), there will be about a 30 second delay." - > - </Info> - - - <Info - helpText="Press next to start the time servers test." - > - </Info> - - - <Freetext - name="freetext1" - variableName="varserver1" - helpText="Primary Time Server:" - editable="false" - > - </Freetext> - - <Freetext - name="freetext2" - variableName="varserver2" - helpText="Secondary Time Server:" - editable="false" - > - </Freetext> - - <Freetext - name="freetext3" - variableName="wiz_timezone" - helpText="Time zone:" - editable="false" - > - </Freetext> - - </Page> - <Page - helpURL="file:/usr/share/doc/mandrake/${LANG}/ref.html/wiz-time.html" - name="server_not_responding" - executionLevel="NORMAL" - nextFinish="false" - canBack="true" - canCancel="true" - func="chooser4" - > - - - <Target - targetName="ciao" - jumpIndex="1" - > - </Target> - - <Target - targetName="test_server" - jumpIndex="2" - > - </Target> - - <Info - helpText="WARNING" - > - </Info> - - <Info - helpText="The time servers are not responding. The causes could be:" - > - </Info> - - <Info - helpText="- non existent time servers" - > - </Info> - - <Info - helpText="- no outside network" - > - </Info> - - <Info - helpText="- other reasons..." - > - </Info> - - - <Info - helpText="You can try again to contact time servers, or save configuration without actually setting time." - > - </Info> - - <Chooser - name="chooser4" - variableName="chooser4" - helpFontName="Default" - helpFontStyle="plain" - helpFontSize="12" - editable="false" - > - - <Option - value="try_again" - description="Try again" - > - </Option> - - <Option - value="save_quit" - description="Save config without test" - > - </Option> - </Chooser> - </Page> - - <Page - helpURL="file:/usr/share/doc/mandrake/${LANG}/ref.html/wiz-time.html" - name="ciao" - nextButtonText="Quit" - executionLevel="NORMAL" - nextFinish="true" - canBack="false" - canCancel="false" - > - - - <Info - helpText="Time server configuration saved" - > - </Info> - - - <Info - helpText="Your server can now act as a time server for your local network." - > - </Info> - - </Page> -</Wizard> |