Guest User

ComputerCleanUp.py

a guest
Jul 17th, 2013
559
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 2.01 KB | None | 0 0
  1. # 2013.07.17 09:18:31 Central Europe Daylight Time
  2. # Embedded file name: ComputerCleanUp.py
  3. import os
  4. Start = 0
  5. Mode = 0
  6. UI = ''
  7. ActionA = False
  8. ActionB = False
  9. ActionC = False
  10. ActionD = False
  11. ActionE = False
  12. print '\t\t\t   Linux Profomance-Booster  Version 13.6'
  13. print '\t\t\t\t Press Enter To Begin...'
  14. Start = raw_input()
  15. print 'Select Mode:'
  16. print '1)Admin mode (Select only if you are the admin)'
  17. print '2)User mode (Recomended)'
  18. Mode = raw_input()
  19. print ''
  20. print ''
  21. if Mode == '1':
  22.     print 'Remove Patial, Uneeded, And Obsolete Packages (Y/N?)'
  23.     UI = raw_input()
  24.     if UI == 'Y':
  25.         ActionA = True
  26.     print 'Clear Temporary Files (Y/N?)'
  27.     UI = raw_input()
  28.     if UI == 'Y':
  29.         ActionB = True
  30.     print 'Clear Unused Thumbnails (Y/N)'
  31.     UI = raw_input()
  32.     if UI == 'Y':
  33.         ActionC = True
  34.     print 'Clear Downloads Folder (Y/N)'
  35.     UI = raw_input()
  36.     if UI == 'Y':
  37.         ActionD = True
  38.     print 'Empty Trash (Y/N)'
  39.     UI = raw_input()
  40.     if UI == 'Y':
  41.         ActionE = True
  42. if Mode == '2':
  43.     print 'Clear Unused Thumbnails (Y/N)'
  44.     UI = raw_input()
  45.     if UI == 'Y':
  46.         ActionC = True
  47.     print 'Clear Downloads Folder (Y/N)'
  48.     UI = raw_input()
  49.     if UI == 'Y':
  50.         ActionD = True
  51.     print 'Empty Trash (Y/N)'
  52.     UI = raw_input()
  53.     if UI == 'Y':
  54.         ActionE = True
  55. if ActionA == True:
  56.     os.system('sudo apt-get clean -f')
  57.     os.system('sudo apt-get autoremove -f')
  58.     os.system('sudo apt-get autoclean -f')
  59. if ActionB == True:
  60.     os.system('sudo rm -rf /tmp/*')
  61. if ActionC == True:
  62.     os.system('rm -f ~/.thumbnails/normal/*')
  63. if ActionD == True:
  64.     os.system('rm -r ~/Downloads/*')
  65. if ActionE == True:
  66.     os.system('rm -rf ~/.local/share/Trash/*')
  67. print ''
  68. print ''
  69. print ''
  70. print 'Clean Up Compleated!'
  71. print 'Hit Enter To Exit.'
  72. Start = raw_input()
  73. # okay decompyling C:\temp\ComputerCleanUp.pyc
  74. # decompiled 1 files: 1 okay, 0 failed, 0 verify failed
  75. # 2013.07.17 09:18:31 Central Europe Daylight Time
Advertisement
Add Comment
Please, Sign In to add comment