From 31522fad893f7ecc836dc215b6b79daaaa64ce65 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Fri, 26 Feb 2010 20:38:08 -0600 Subject: Add some additional fields to package import We can capture the build date, compressed size, and installed size when reporead runs. Even if we don't show all of it, we should pull it in. FS#14270 is requesting that the package size be shown on the website. Signed-off-by: Dan McGee --- devel/management/commands/reporead.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'devel') diff --git a/devel/management/commands/reporead.py b/devel/management/commands/reporead.py index 733e9d3e..90337b8d 100755 --- a/devel/management/commands/reporead.py +++ b/devel/management/commands/reporead.py @@ -137,6 +137,10 @@ def populate_pkg(dbpkg, repopkg, timestamp=None): dbpkg.pkgdesc = repopkg.desc dbpkg.license = repopkg.license dbpkg.url = repopkg.url + dbpkg.compressed_size = int(repopkg.csize) + dbpkg.installed_size = int(repopkg.isize) + dbpkg.build_date = datetime.utcfromtimestamp(int(repopkg.builddate)) + dbpkg.needupdate = False dbpkg.last_update = timestamp dbpkg.save() -- cgit v1.2.3-54-g00ecf