Jump to content

Problem with "Open Terminal Here" action [Fixed in 2.1 b216]


Recommended Posts

Posted

When I was using "Open Terminal here" action today, I found that this command is not executed with arguments quoted.

 

For example, here I got a folder named "a&b", when I perform "Open Terminal Here", a error happened. Why?

 

I am guessing that the terminal actually executes such a command, "cd a&b", so it is apparently that this command is split by the symbol "&". I hope you can fix this bug just by surrounding the target folder path with a pair of quotes like this: 

 

    cd "a&b"

 

instead of:

 

    cd a&b

 

thanks~

 

by iSMart

Posted

When I was using "Open Terminal here" action today, I found that this command is not executed with arguments quoted.

 

For example, here I got a folder named "a&b", when I perform "Open Terminal Here", a error happened. Why?

 

I am guessing that the terminal actually executes such a command, "cd a&b", so it is apparently that this command is split by the symbol "&". I hope you can fix this bug just by surrounding the target folder path with a pair of quotes like this: 

 

    cd "a&b"

 

instead of:

 

    cd a&b

 

thanks~

 

by iSMart

 

Ah nicely spotted, the & character needs escaping. I'll get this fixed up in the next release :)

 

Cheers,

Andrew

Posted

When I was using "Open Terminal here" action today, I found that this command is not executed with arguments quoted.

 

For example, here I got a folder named "a&b", when I perform "Open Terminal Here", a error happened. Why?

 

I am guessing that the terminal actually executes such a command, "cd a&b", so it is apparently that this command is split by the symbol "&". I hope you can fix this bug just by surrounding the target folder path with a pair of quotes like this: 

 

    cd "a&b"

 

instead of:

 

    cd a&b

 

thanks~

 

by iSMart

 

This should now be fixed in the 2.1 b216 pre-release :)

  • 8 years later...
Posted

I now experience the issue described here in Alfred 4.6.3 on macOS 12.2 when using the "Open Terminal Here" file action with a file that has a path with spaces in it, the path is not quoted so the cd command in iTerm fails. If this can be reproduced by others I hope this can be fixed, thank you.

Posted
3 hours ago, cands said:

so the cd command in iTerm fails

 

If you're using iTerm, then you'll be using custom AppleScript in Alfred's Features > Terminal preferences, and this is where the root of your issue will be.

 

There are plenty of people also using iTerm, so perhaps check around to see if there is some up to date AppleScript available.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...