void (@NotNull AnActionEvent e) { Presentation presentation = e.getPresentation(); Project project = e.getData(CommonDataKeys.PROJECT); if (project != null) { final String vcsName = getVcsName(project); presentation.setVisible(vcsName != null && ProjectLevelVcsManager.getInstance(project).checkVcsIsActive(vcsName)); } else { presentation.setVisible(false); } presentation.setEnabled(presentation.isVisible()); }