Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using java to chmod files in Unix

 
Anupreet Arora
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can we use java to reliable change permissions (chmod) or owner (chown) of files in a unix file system ?

Any ideas will be most appreciated

Thanks
Anupreet
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24211
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sure. Use the Runtime.exec() family of methods to execute the chmod/chown programs.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic