Skip to content

Emacs Support added #79

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all 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
11 changes: 11 additions & 0 deletions cli/src/main/java/dev/starfix/Starfix.java
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,10 @@ public static void editConfig() throws Exception {
ide = isWindows() ?"idea64.exe":"idea";
System.out.println("\n--------Selected IDE:IntelliJ_IDEA--------");
break;
} else if (id == 4) {
ide = isWindows() ?"emacsclientw.exe":"emacsclient";
System.out.println("\n--------Selected IDE:EMACS Client--------");
break;
} else
System.out.println("\n--------Invalid Input!! Try Again--------");
}
Expand Down Expand Up @@ -272,6 +276,13 @@ public static void launch_editor(Path directory, String ide, String path, String
filePath = filePath.replace("#",":");
runCommand(directory.getParent(), ide,path,filePath);
}
if(ide.equals("emacsclientw.exe")||ide.equals("emacsclient")){
//emacsclient +4 info.txt
String lineNumber = "+"+filePath.substring(filePath.lastIndexOf("#")+1);
filePath = filePath.substring(0,filePath.lastIndexOf("#"));

runCommand(directory.getParent(), ide,lineNumber,filePath);
}

}
else{
Expand Down