forked from endorphant/ttbp
		
	Merge pull request #2 from Sanqui/master
Fix lists when encountering inacessible entries
This commit is contained in:
		
						commit
						9e372b4160
					
				| @ -290,7 +290,10 @@ def meta(entries = FILES): | |||||||
| 
 | 
 | ||||||
|     for filename in entries: |     for filename in entries: | ||||||
|       mtime = os.path.getmtime(filename) |       mtime = os.path.getmtime(filename) | ||||||
|       wc = subprocess.check_output(["wc","-w",filename]).split()[0] |       try: | ||||||
|  |         wc = subprocess.check_output(["wc","-w",filename], stderr=subprocess.STDOUT).split()[0] | ||||||
|  |       except subprocess.CalledProcessError: | ||||||
|  |         wc = "???" | ||||||
|       timestamp = time.strftime("%Y-%m-%d at %H:%M", time.localtime(mtime)) |       timestamp = time.strftime("%Y-%m-%d at %H:%M", time.localtime(mtime)) | ||||||
|       date = "-".join(parse_date(filename)) |       date = "-".join(parse_date(filename)) | ||||||
|       author = os.path.split(os.path.split(os.path.split(os.path.split(filename)[0])[0])[0])[1] |       author = os.path.split(os.path.split(os.path.split(os.path.split(filename)[0])[0])[0])[1] | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user