Skip to content

Commit a545440

Browse files
committed
Add cleanup process
1 parent e1d6d32 commit a545440

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

palint.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,11 @@ def process_project():
122122
return EXIT_FAILURE
123123
print('Completed!')
124124

125+
print('\n')
126+
print('Performing cleanup...')
127+
cleanup()
128+
print('Completed!')
129+
125130

126131
def check_files(files, optionals, libraries):
127132
has_error = False
@@ -215,6 +220,7 @@ def format_code(files, optionals):
215220
os.system(cmd)
216221

217222
for name in files:
223+
print('\n')
218224
print('Showing diff of file {} ...'.format(name))
219225

220226
status = os.system('diff {0} {1}/{0}'.format(name, backup_folder))
@@ -226,6 +232,7 @@ def format_code(files, optionals):
226232
print('Reverted file ' + name)
227233

228234
for name in optionals:
235+
print('\n')
229236
print('Showing diff of file {} ...'.format(name))
230237

231238
status = os.system('diff {0} {1}/{0}'.format(name, backup_folder))
@@ -237,6 +244,11 @@ def format_code(files, optionals):
237244
print('Reverted file ' + name)
238245

239246

247+
def cleanup():
248+
""" Clean compiled class files. """
249+
os.system('rm *.class')
250+
251+
240252
def error(msg):
241253
""" Show error message to user. """
242254
sys.stdout.write('[Error] ' + msg + '\n')

0 commit comments

Comments
 (0)