Last change
on this file since 34 was
32,
checked in by meynadie, 16 years ago
|
Ajout de scripts à linker dans ~/bin
|
-
Property svn:executable set to
*
|
File size:
707 bytes
|
Line | |
---|
1 | #!/bin/env python |
---|
2 | |
---|
3 | import string |
---|
4 | import sys |
---|
5 | from datetime import * |
---|
6 | |
---|
7 | |
---|
8 | |
---|
9 | dts = [] |
---|
10 | noms = [] |
---|
11 | |
---|
12 | for line in file(sys.argv[1]): |
---|
13 | line_s = string.split(line) |
---|
14 | if (len(line_s) > 2): |
---|
15 | noms.append(line_s[0]) |
---|
16 | [heure,minute] = string.split(line_s[1],":") |
---|
17 | [annee,mois,jour] = string.split(line_s[2],"-") |
---|
18 | dts.append(datetime(int(annee), |
---|
19 | int(mois), |
---|
20 | int(jour), |
---|
21 | int(heure), |
---|
22 | int(minute))) |
---|
23 | |
---|
24 | for i in range(len(noms)): |
---|
25 | delta = dts[i]-dts[0] |
---|
26 | print "%-35s %f %s" % (noms[i], |
---|
27 | delta.seconds/(60.*90), |
---|
28 | dts[i].isoformat()) |
---|
Note: See
TracBrowser
for help on using the repository browser.