final VCSContext ctx = context;
RequestProcessor rp = Git.getInstance().getRequestProcessor();
GitProgressSupport support = new GitProgressSupport() {
public void perform() {
GitModuleConfig config = GitModuleConfig.getDefault();
int status = getActionStatus(ctx);
Set<File> files = ctx.getRootFiles();
List<String> paths = new ArrayList<String>(files.size());
for (File file : files) {
paths.add(file.getAbsolutePath());
}
if (isCanceled()) {
return;
}
if (status == EXCLUDING) {
config.addExclusionPaths(paths);
} else if (status == INCLUDING) {
config.removeExclusionPaths(paths);
}
}
};
support.start(rp, "", ""); // NOI18N
}