Eval 1 Syntax Error Unterminated Quoted String
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site syntax error unterminated quoted string xampp About Us Learn more about Stack Overflow the company Business Learn more about syntax error: unterminated quoted string python hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join docker syntax error: unterminated quoted string the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Why I got “sh: 1:
Docker /bin/sh: 1: Syntax Error: Unterminated Quoted String
Syntax error: Unterminated quoted string” when I run my Python program? up vote 1 down vote favorite I want to count how many lines of code I have written. Here is the Python code: import os import sys EXT = ['.c','.cpp','.java','.py'] def main(): l = [] if os.path.isdir(sys.argv[1]): for root, dirs, files in os.walk(sys.argv[1]): l.extend([os.path.join(root, name) for name in files]) else: l.append(sys.argv[1]) params = ["'"+p+"'" phantomjs syntax error unterminated quoted string for p in l if os.path.splitext(p)[1] in EXT] result = os.popen("wc -l %s "%" ".join(params)).read() print result if __name__ == '__main__': main() Before this, it was running as expected. But today, it give me this error: sh: 1: Syntax error: Unterminated quoted string I don't know what happened. python shell share|improve this question edited Feb 17 '14 at 17:09 nisargshah95 359422 asked Aug 31 '13 at 3:12 maemual 1114 2 How are you executing this script? –Johnsyweb Aug 31 '13 at 3:17 @Johnsyweb python program.py . –maemual Aug 31 '13 at 3:42 1 Try adding print params before your popen line. Do any of the elements in params have a single quote in them? –SethMMorton Aug 31 '13 at 5:09 2 you should also consider using the newer subprocess module instead of popen –sapi Aug 31 '13 at 5:52 @sapi THX, i wil try it. –maemual Sep 1 '13 at 2:57 add a comment| 3 Answers 3 active oldest votes up vote 2 down vote accepted Your Python script is missing a shebang line. Add the following to the top of your file: #!/usr/bin/env python Then you shoul
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack makefile syntax error: unterminated quoted string Overflow the company Business Learn more about hiring developers or posting ads with us Unix
Syntax Error: Unterminated Quoted String Heroku
& Linux Questions Tags Users Badges Unanswered Ask Question _ Unix & Linux Stack Exchange is a question and answer site for
Emulator: Syntax Error: Unterminated Quoted String
users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute: Sign up Here's how it works: Anybody can ask a question Anybody can answer The best answers are voted up http://stackoverflow.com/questions/18544112/why-i-got-sh-1-syntax-error-unterminated-quoted-string-when-i-run-my-python and rise to the top sh -c: Unterminated quoted string error [duplicate] up vote 2 down vote favorite This question already has an answer here: Quoting in a function results in error 1 answer I've spent hours trying to understand the following error. My Script CMD="sh -c 'echo \"a\"'" $CMD Error: "a"': 1: "a"': Syntax error: Unterminated quoted string of course when I do echo $CMD and paste the result, it works as expected... http://unix.stackexchange.com/questions/190008/sh-c-unterminated-quoted-string-error What is the cause of the error? Edit: I'm asking for an explanation not only a workaround. Therefore, I think the following link doesn't answer my question: Quoting in a function results in error bash shell quoting escape-characters share|improve this question edited Mar 14 '15 at 10:28 asked Mar 13 '15 at 19:05 klarezz 1414 marked as duplicate by Gillesbash Users with the bash badge can single-handedly close bash questions as duplicates and reopen them as needed. Mar 13 '15 at 22:51 This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question. add a comment| 2 Answers 2 active oldest votes up vote 2 down vote That cannot work. When your shell performs word splitting, you will have four arguments: sh -c 'echo "a"' To accomplish this, you must use a bash array: cmd=( sh -c 'echo "a"' ) "${cmd[@]}" share|improve this answer answered Mar 13 '15 at 19:18 glenn jackman 33.2k24072 Thanks, I didn't know aboud word splitting performed by the shell, I'm going to check this out! –klarezz Mar 13 '15 at 19:23 See also I'm trying to put a command in a variable, but the complex cases always fail! –glenn jackman Mar 13 '15 at 19:24
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings http://superuser.com/questions/678386/syntax-error-unterminated-quoted-string-running-run-file and policies of this site About Us Learn more about Stack Overflow http://steveracanovic.blogspot.com/2013/12/receiving-startweblogicsh-1-eval-syntax.html the company Business Learn more about hiring developers or posting ads with us Super User Questions Tags Users Badges Unanswered Ask Question _ Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute: Sign up Here's how syntax error it works: Anybody can ask a question Anybody can answer The best answers are voted up and rise to the top Syntax error: Unterminated quoted string - running .run file up vote 2 down vote favorite 1 I am trying to run a .run file, I log in as SU and run the following command: sh xampp-linux-x64-1.8.3-1-installer.run but I am getting unterminated quoted string the following error: Syntax error: Unterminated quoted string What is the cause of this? installation debian crunchbang share|improve this question edited Nov 7 '14 at 13:38 Hennes 51k776121 asked Nov 20 '13 at 14:55 ColinShewell 1582312 The cause is stated (Syntax Error). Are you more interested in how to fix it? If so, is it plain text (can you cat *.run)? –nerdwaller Nov 20 '13 at 15:00 The output is just gibberish. –ColinShewell Nov 20 '13 at 15:03 add a comment| 4 Answers 4 active oldest votes up vote 4 down vote accepted The cause is probably an unterminated quoted string in the installer. (well duh!). Either run it with the -x option to get more debug information, or open the installer in an editor and look for unmatched pairs of quotes. Example: #!/usr/bin/env bash #My demo installer! # echo "starting here!" echo "and an error in this line echo "We will never get here!" Notice the missing closing quote (") in the second echo line. Edit: I just downloaded a file called xampp-linux-x64-1.8.3-1-installer.run from sourc
by Steve Racanovic | Posted in | Posted on 3:40 PM 0 I'm using Linux Mint 16, and when I try to start the Integrated Weblogic Server (Run -> Start Server Instance) in JDeveloper I get this error: *** Using port 7101 ***/home/steve/.jdeveloper/system11.1.1.6.38.62.29/DefaultDomain/bin/startWebLogic.sh[waiting for the server to complete its initialization...]/home/steve/.jdeveloper/system11.1.1.6.38.62.29/DefaultDomain/bin/startWebLogic.sh: 1: eval: Syntax error: Unterminated quoted stringProcess exited. To workaround this, I changed the sha-bang in startWebLogic.sh script to run bash. i.e. #!/bin/bash You also need to do the same for stopWebLogic.sh script to stop instance later. Comments (0) Post a Comment Newer Post Older Post Home Subscribe to: Post Comments (Atom) Useful Link The Blas from Pas Followers About Me Steve Racanovic View my complete profile Blog Archive ► 2016 (1) ► February (1) ▼ 2013 (3) ▼ December (1) Receiving 'startWebLogic.sh: 1: eval: Syntax error... ► September (1) ► February (1) ► 2012 (4) ► May (1) ► March (1) ► February (2) ► 2011 (4) ► November (1) ► September (1) ► March (1) ► January (1) ► 2010 (6) ► September (1) ► June (1) ► May (2) ► April (2) ► 2009 (14) ► December (1) ► September (2) ► August (3) ► July (3) ► May (1) ► April (2) ► February (1) ► January (1) ► 2008 (4) ► November (1) ► October (1) ► March (2) ► 2007 (4) ► November (1) ► October (2) ► September (1) Labels ADF (4) Binding (2) Datasources (2) DBMS Callout (3) J2CA (1) Java Stored Procedure (1) JDBC (11) JDev (4) JMS Provider (4) jpub (2) OAS (3) OC4J (4) Oracle (4) RMI (2) Solaris (1) Web Services (4) Weblogic (2) © All Rights Reserved. The views expressed on this blog are my own and do not necessarily reflect the views of my employer.Steve's Blog | Theme by : Best Hosting | Converted into Blogger Templates by Theme Craft