Gentoo Archives: gentoo-user

From: Thanasis <thanasis@××××××××××.org>
To: Gentoo mailing list <gentoo-user@l.g.o>
Subject: [gentoo-user] resume_list.py
Date: Thu, 07 Jun 2012 18:28:43
Message-Id: 4FD0F233.2060200@asyr.hopto.org
1 I used to use this python script to display the packages that would be
2 emerged when using the "--resume" option. But it does't work with
3 python3.2 interpreter:
4
5 ~ # cat resume_list.py
6 import portage
7
8 resume_list=portage.mtimedb["resume"]["mergelist"]
9
10 for i in range(len(resume_list)):
11 print "="+resume_list[i][2]
12 ~ #
13 ~ # python ~/resume_list.py
14 File "/root/resume_list.py", line 6
15 print "="+resume_list[i][2]
16 ^
17 SyntaxError: invalid syntax
18 ~ #
19
20 Q: Is there a way to make it work with python3.2 ?

Replies

Subject Author
Re: [gentoo-user] resume_list.py Paul Hartman <paul.hartman+gentoo@×××××.com>
Re: [gentoo-user] resume_list.py Michael Mol <mikemol@×××××.com>