Path: ...!news.misty.com!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!cleanfeed2-b.proxad.net!nnrp1-1.free.fr!not-for-mail From: Thomas Newsgroups: fr.comp.os.unix Mail-Copies-To: nobody Subject: Re: obtenir le fuseau horaire References: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit User-Agent: MT-NewsWatcher/3.5.3b3 (Intel Mac OS X) Date: Tue, 30 Nov 2021 18:35:30 +0100 Message-ID: Lines: 30 Organization: Guest of ProXad - France NNTP-Posting-Date: 30 Nov 2021 18:35:30 CET NNTP-Posting-Host: 91.175.52.121 X-Trace: 1638293730 news-4.free.fr 4967 91.175.52.121:7631 X-Complaints-To: abuse@proxad.net Bytes: 1634 In article , Christian Weisgerber wrote: > On 2021-11-30, Thomas wrote: > > > y a-t-il une option avec la commande date, pour obtenir le fuseau > > horaire ? > $ date +%z > +0100 merci :-) pb suivant : comment exploiter ça pour les calculs ? $ var1=$( date "+%z" ) ++ date +%z + var1=+0100 $ var2=$(( var1 )) + var2=64 je pensais qu'en analysant la chaine de texte ça déterminerais la valeur 100. qu'est-ce qui m'échappe ? -- RAPID maintainer http://savannah.nongnu.org/projects/rapid/