Skip to content
This repository was archived by the owner on Apr 23, 2025. It is now read-only.

fix: start dev on podman does not work if odo can't retrieve podman status #773

Merged
merged 13 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
94 changes: 0 additions & 94 deletions src/it/projects/springboot-rest/.circleci/config.yml

This file was deleted.

12 changes: 0 additions & 12 deletions src/it/projects/springboot-rest/.circleci/run_tests_with_fmp.sh

This file was deleted.

21 changes: 0 additions & 21 deletions src/it/projects/springboot-rest/.circleci/settings.xml

This file was deleted.

23 changes: 0 additions & 23 deletions src/it/projects/springboot-rest/.editorconfig

This file was deleted.

This file was deleted.

Binary file not shown.

This file was deleted.

10 changes: 10 additions & 0 deletions src/it/projects/springboot-rest/HELP.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Getting Started

### Reference Documentation

For further reference, please consider the following sections:

* [Official Apache Maven documentation](https://maven.apache.org/guides/index.html)
* [Spring Boot Maven Plugin Reference Guide](https://docs.spring.io/spring-boot/docs/2.3.5.RELEASE/maven-plugin/reference/html/)
* [Create an OCI image](https://docs.spring.io/spring-boot/docs/2.3.5.RELEASE/maven-plugin/reference/html/#build-image)

Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package com.example.demo;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
@SpringBootApplication
public class DemoApplication {

@RequestMapping("/")
String home() {
return "Hello World!";
}

public static void main(String[] args) {
SpringApplication.run(DemoApplication.class, args);
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package com.example.demo;

import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;

@SpringBootTest
class DemoApplicationTests {

@Test
void contextLoads() {
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
******************************************************************************/
package org.jboss.tools.intellij.openshift.actions.component;

import com.intellij.openapi.actionSystem.AnActionEvent;
import org.jboss.tools.intellij.openshift.tree.application.ComponentNode;
import org.jboss.tools.intellij.openshift.utils.odo.Component;
import org.jboss.tools.intellij.openshift.utils.odo.ComponentFeature;

Expand All @@ -33,4 +35,16 @@ protected String getCustomizedPresentation(Component component) {
}
}

@Override
public void update(AnActionEvent e) {
super.update(e);
if (e.getPresentation().isVisible()) {
Object node = adjust(getSelected(getTree(e)));
if (!(node instanceof ComponentNode)) {
return;
}
ComponentNode componentNode = (ComponentNode) node;
e.getPresentation().setEnabled(componentNode.getComponent().getInfo().isLocalPodmanPresent());
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,6 @@ public void update(AnActionEvent e) {
}
ComponentNode componentNode = (ComponentNode) node;
Component component = componentNode.getComponent();
Odo odo = componentNode.getRoot().getOdo().getNow(null);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed because it causes slow actions updates.

if (odo == null) {
return;
}
e.getPresentation().setText(getCustomizedPresentation(component));
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public String getTelemetryActionName() {
@Override
public boolean isVisible(Object selected) {
return (selected instanceof NamespaceNode)
|| (selected instanceof ApplicationsRootNode && ((ApplicationsRootNode) selected).isLogged());
|| (selected instanceof ApplicationsRootNode && ((ApplicationsRootNode) selected).isLogged());
}

private static final class ClusterProjects {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ private void createProject(String newProject, @NotNull Odo odo) {
try {
odo.createProject(newProject);
notification.expire();
NotificationUtils.notifyInformation("Create " + kind, kind + " " + newProject + " successfully created");
NotificationUtils.notifyInformation("Create " + kind, kind + " " + newProject + " successfully created");
sendTelemetryResults(TelemetryResult.SUCCESS);
} catch (IOException | CompletionException e) {
notification.expire();
Expand Down
Loading