euscanwww/commands: don't keep all logs
Signed-off-by: Corentin Chary <corentincj@iksaif.net>
This commit is contained in:
		@@ -105,12 +105,16 @@ class Command(BaseCommand):
 | 
			
		||||
            self.store_result(options, package, log)
 | 
			
		||||
 | 
			
		||||
    def store_result(self, options, package, log):
 | 
			
		||||
        # Remove previous logs
 | 
			
		||||
        EuscanResult.objects.filter(package=package).delete()
 | 
			
		||||
 | 
			
		||||
        obj = EuscanResult()
 | 
			
		||||
        obj.package = package
 | 
			
		||||
        obj.result = log
 | 
			
		||||
        obj.datetime = datetime.now()
 | 
			
		||||
        obj.save()
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    def store_package(self, options, cpv):
 | 
			
		||||
        cat, pkg, ver, rev = portage.catpkgsplit(cpv)
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user