删除workspace下的vss的scc文件

public class DeleteAA {

	 public static void main(String[] args) {

	  DeleteAA aa=new DeleteAA();

	  aa.delete(new File("G:\\testEnvironment\\workspace\\location"));

	 }

	 

	 private void delete(File file){

	  if(file.isDirectory()){

	   File[] files = file.listFiles();

	   for (File file2 : files) {

	    delete(file2);

	   }

	  }else{

	   String name=file.getName();

	   if(name.endsWith(".scc")){

	    System.out.println(file.getAbsolutePath());

	    file.delete();

	   }

	  }

	 }



	}



你可能感兴趣的:(workspace)