mirror of
				https://gitlab.com/ytdl-org/youtube-dl.git
				synced 2025-11-03 20:37:08 -05:00 
			
		
		
		
	Add an "epoch" keyword to the output template
This commit is contained in:
		@@ -260,7 +260,9 @@ class FileDownloader(object):
 | 
			
		||||
			return
 | 
			
		||||
 | 
			
		||||
		try:
 | 
			
		||||
			filename = self.params['outtmpl'] % info_dict
 | 
			
		||||
			template_dict = dict(info_dict)
 | 
			
		||||
			template_dict['epoch'] = unicode(long(time.time()))
 | 
			
		||||
			filename = self.params['outtmpl'] % template_dict
 | 
			
		||||
			self.report_destination(filename)
 | 
			
		||||
		except (ValueError, KeyError), err:
 | 
			
		||||
			self.trouble('ERROR: invalid output template or system charset: %s' % str(err))
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user