what is the accurate command_line for deleting a folder in /usr/local?

This question already has an answer here:

  • How to delete a non-empty directory in Terminal? 5 answers

i was unsuccessful for installing jdk8 and i want to delete the java folder in my usr/local.

cd /usr/local rm java error :rm: cannot remove ‘java’: Is a directory rmdir java error :rmdir: failed to remove ‘java’: Permission denied 

what is the accurate cmd line?

Replay

sudo rm -r /usr/local/java will suffice. sudo gives you the appropriate permissions to delete the directory and the -r ("r" stands for recursive) option is needed to delete the contents of the directory recursively.

Please make sure you intend to delete the /usr/local/java directory before running the command above.

Category: command line Time: 2016-07-28 Views: 0
Tags: command line

Related post

iOS development

Android development

Python development

JAVA development

Development language

PHP development

Ruby development

search

Front-end development

Database

development tools

Open Platform

Javascript development

.NET development

cloud computing

server

Copyright (C) avrocks.com, All Rights Reserved.

processed in 0.109 (s). 12 q(s)