Java tutorial
//package com.java2s; //License from project: Apache License import java.io.File; import java.io.IOException; public class Main { public static void changeFilePermission(File file) { try { String command = "chmod 666 " + file.getAbsolutePath(); Runtime.getRuntime().exec(command); } catch (IOException e) { e.printStackTrace(); } } }