TransWikia.com

syntax error near unexpected token `('

Ask Different Asked by jkershaw on December 17, 2021

I was given a script to automate some processes. This script gets executed on a Mac in Terminal. The script is a bash script.

However, Terminal is showing

syntax error near unexpected token `('

in

ManagerDaemon="/Library/LaunchDaemons/com.graphisoft.PortalServerService-v24.0(Manager-2020-07-21).plist"

What could be the issue? How can I remove the error?

2 Answers

ok, so I think the answer has to do with "curly" quotes or "smart" quotes as opposed to "straight" quotes.

I had been using a text editor to edit the script. However, when I switched to an actual code editor, it noticed several "curly" quotes. I replaced those with straight quotes and all is well.

Answered by jkershaw on December 17, 2021

One possibility is the broken line. Make sure that the line looks like this in your editor (all on one line):

ManagerDaemon="/Library/LaunchDaemons/com.graphisoft.PortalServerServicev24.0(Manager-2020-07-21).plist"

Rather than this (with a line break in the middle):

ManagerDaemon="/Library/LaunchDaemons/com.graphisoft.PortalServerService- v24.0(Manager-2020-07-21).plist"

Answered by Scot on December 17, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP