Home > Uncategorized > Being on time

Being on time

I hate:

  • receiving e-mail from the future
  • having a make being lost
  • having messy CVS log

I love having my PC clock being perfectly set.

The problem is that I’am behind an http proxy. I first thought to tunnel a NTP traffic (which is UDP) into a TCP tunnel using netcat and wrap this TCP into a ssh tunnel through an HTTP tunnel. Lost ? No matter because there is a really easier way to do this:

#! /bin/sh
myTime=`wget --proxy-passwd=$proxy_passwd -O - http://www.timeanddate.com/worldclock/city.html?n=195| \   grep "Current time" | awk '{ print $8 $9 }'`
date `date -d "$myTime" +%m%d%H%M.%S`
  1. No comments yet.
  1. December 4, 2007 at 22:33

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: