Search in sources :

Example 1 with LeiningenRunnerParameters

use of de.janthomae.leiningenplugin.run.LeiningenRunnerParameters in project intellij-leiningen-plugin by derkork.

the class RunBuildAction method actionPerformed.

@Override
public void actionPerformed(AnActionEvent anActionEvent) {
    Project project = anActionEvent.getData(PlatformDataKeys.PROJECT);
    List<String> goals = anActionEvent.getData(LeiningenDataKeys.LEININGEN_GOALS);
    if (goals == null || goals.isEmpty()) {
        return;
    }
    LeiningenProject leiningenProject = anActionEvent.getData(LeiningenDataKeys.LEININGEN_PROJECT);
    if (leiningenProject == null) {
        return;
    }
    LeiningenRunnerParameters params = new LeiningenRunnerParameters(goals, leiningenProject.getWorkingDir());
    LeiningenRunConfigurationType.runConfiguration(project, params, anActionEvent.getDataContext());
}
Also used : LeiningenProject(de.janthomae.leiningenplugin.project.LeiningenProject) Project(com.intellij.openapi.project.Project) LeiningenRunnerParameters(de.janthomae.leiningenplugin.run.LeiningenRunnerParameters) LeiningenProject(de.janthomae.leiningenplugin.project.LeiningenProject)

Aggregations

Project (com.intellij.openapi.project.Project)1 LeiningenProject (de.janthomae.leiningenplugin.project.LeiningenProject)1 LeiningenRunnerParameters (de.janthomae.leiningenplugin.run.LeiningenRunnerParameters)1