1

I'm trying to find an easy way using launchy to open files via n++ that might not normally be that way. For example, if I have an authohotkey (ahk) file that I want to edit, I'd like to be able to use a script or command to launch it in notepad++.

I think there might be a way to do this with batch looking at this question, but I'm not sure how to make it so I can call it in launchy with the file name.

Eabryt
  • 151
  • 1
  • 7
  • 1
    It's probably worth mentioning that you don't really need Launchy to open random files in Notepad++. The batch file linked in you original question supports simply dropping files onto it to open them in that program. The quick version of this would saving a batch file on your desktop with `START notepad++ %*`. – Anaksunaman Jan 27 '20 at 01:26
  • That actually helps a bunch, thank you. I'll have to mess around with it to see the best way to deal with paths, but I really appreciate the suggestion. – Eabryt Jan 27 '20 at 13:48
  • Glad I could assist. =) – Anaksunaman Jan 27 '20 at 22:06

1 Answers1

1

Using the information given by Anaksunaman, I was able to come up with what appears to be a workable solution.

I created a bat file in the directory I want to search through that simply says

for /f %%i in ('dir /S /b %*') do SET FNAME=%%i
START notepad++ %FNAME%

This will search through the directory of the file as well as any subdirectories.

This isn't really directly related to Launchy, but it does work when launched through Launchy.

Eabryt
  • 151
  • 1
  • 7