mirror of
				https://github.com/kepler155c/opus
				synced 2025-10-31 07:33:00 +00:00 
			
		
		
		
	 9c4aac27f8
			
		
	
	9c4aac27f8
	
	
	
		
			
			Kind of make the program look better as the 'sys/apis' line is the only one not to do fs.exists. Also fixes error when opus is nested inside a potatOS instance.
		
			
				
	
	
		
			21 lines
		
	
	
		
			577 B
		
	
	
	
		
			Lua
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			577 B
		
	
	
	
		
			Lua
		
	
	
	
	
	
| local fs = _G.fs
 | |
| 
 | |
| local function deleteIfExists(path)
 | |
|   if fs.exists(path) then
 | |
|     fs.delete(path)
 | |
|     print("Deleted outdated file at: "..path)
 | |
|   end
 | |
| end
 | |
| -- cleanup outdated files
 | |
| deleteIfExists('sys/apps/shell')
 | |
| deleteIfExists('sys/etc/app.db')
 | |
| deleteIfExists('sys/extensions')
 | |
| deleteIfExists('sys/network')
 | |
| deleteIfExists('startup')
 | |
| deleteIfExists('sys/apps/system/turtle.lua')
 | |
| deleteIfExists('sys/autorun/gps.lua')
 | |
| deleteIfExists('sys/autorun/gpshost.lua')
 | |
| deleteIfExists('sys/apps/network/redserver.lua')
 | |
| deleteIfExists('sys/apis')
 | |
| deleteIfExists('sys/autorun/apps.lua')
 |