Create a bash shell script that removes all files whose
names end with a "~" from your home directory and
subdirectories. Name this script "cleanup.sh"
Answer Posted / alok
find . -name *~ -exec rm -i {} \;
It will ask you before deletion of this file
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
What is sudo command?
Is scripting and coding the same thing?
What are the different communication commands available in the shell?
How to replace following lines, catch (DAOException e) { objLogger.error(this.getClass () + "addUpdateIssues() " + e); throw new BOException(5122); } catch (BOException e) { objLogger.error(this.getClass () + "addUpdateIssues() " + e); throw e; } catch (Exception e) { objLogger.error(this.getClass () + "addUpdateIssues() " + e); throw new BOException(5122); } Needs to be changed in to, catch (DAOException e) { AppException.handleException (null, null, e, null, null, null, "BOException", this.getClass() + "addUpdateIssues() ", null, null, null, null, null, null, null, null, 5122); } catch (BOException e) { AppException.handleException (null, null, null, e, null, null, "BOException", this.getClass() + "addUpdateIssues() ", null, null, null, null, null, null, null, null, 0); } catch (Exception e) { AppException.handleException (null, null, null, null, null, e, "BOException", this.getClass() + "addUpdateIssues() ", null, null, null, null, null, null, null, null, 5122); }
What is .sh file in mac?
What is the difference between bash and shell?
Can shell script run on windows?
What is the command to find out today's date?
What exactly is a shell?
What is the difference between break and continue commands?
How to print pid of the current shell?
How do I set bash as default shell mac?
What happens when you type ls?
What is bash eval?
how will you find the total disk space used by a specific user?