Bin/sh 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 About Us Learn more about Stack Overflow the company Business Learn more about hiring
Docker /bin/sh: 1: Syntax Error: Unterminated Quoted String
developers or posting ads with us Unix & Linux Questions Tags Users Badges Unanswered Ask Question docker syntax error: unterminated quoted string _ Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it
Syntax Error: Unterminated Quoted String Python
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 and rise to the top sh -c: Unterminated quoted string error [duplicate] up vote 2 down makefile : syntax error: unterminated quoted string 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... 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 sh: 2: syntax error: unterminated quoted string heroku 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 32.9k24072 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 Also, spend some time with the bash manual: gnu.org/software/bash/manual/bashref.html#Shell-Expansions –glenn jackman Mar 13 '15 at 19:25 see my answer below! thanks for pointing me in the right direction! –klarezz Mar 13 '15 at 22:20 add a comment| up vote 0 down vote accepted T
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
Phantomjs Syntax Error Unterminated Quoted String
about Stack Overflow the company Business Learn more about hiring developers or posting ads syntax error: unterminated quoted string android with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow
Syntax Error: Unterminated Quoted String Eclipse
is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up /bin/sh: Syntax error: Unterminated quoted string up vote 26 down vote favorite http://unix.stackexchange.com/questions/190008/sh-c-unterminated-quoted-string-error 2 I am trying to get a cronjob to pipe output into a dated file in a specified (folder) location. My crontab entry looks something like this: * * * * * /some/path/test.sh >> $(date "+/home/oompah/logs/%Y%m%d.test.log") What I don't understand is that when I type this command at the console, I get the correct string: echo $(date "+/home/oompah/logs/%Y%m%d.test.log") /home/oompah/logs/20110329.test.log What's causing this error and how may I fix it? bash http://stackoverflow.com/questions/5473876/bin-sh-syntax-error-unterminated-quoted-string version info is: GNU bash, version 4.1.5(1)-release (x86_64-pc-linux-gnu) bash ubuntu share|improve this question asked Mar 29 '11 at 14:09 oompahloompah 2,700114576 The $date() call is correct - the error's most likely in your test.sh script. What's that look like? –Marc B Mar 29 '11 at 14:12 1 Belongs on askubuntu.com or unix.stackexchange.com –Let_Me_Be Mar 29 '11 at 14:20 test.sh simply contains this line echo 'Hello' I don't think that is the cause of the problem –oompahloompah Mar 29 '11 at 14:22 @Let_Me_Be: Although I can see your point, there is a real danger of SO spreading itself so thin, that it ends up with several "specialist" sites with no more than a few dozen or tops couple of hundred people to answer questions. This question is relevant here, because although I have kept it simple (for brevity and clarity), it could very easily broaden to include questions about Python and C++, which are the tasks being run by cron. –oompahloompah Mar 29 '11 at 14:34 Well, that is a discussion for meta. –Let_Me_Be Mar 29 '11 at 14:53 add a comment| 3 Answers 3 active oldest votes up vote 53 down vote accepted You should excape
Support Search GitHub This repository Watch 148 Star 756 Fork 342 Medium/phantomjs Code Issues https://github.com/Medium/phantomjs/issues/392 39 Pull requests 1 Projects 0 Pulse Graphs New issue https://ubuntuforums.org/showthread.php?t=1093894 Unterminated quoted string syntax error when running inside Docker #392 Closed seanemmer opened this Issue Oct 5, 2015 · 7 comments Projects None yet Labels None yet Milestone No milestone Assignees No one assigned 5 participants seanemmer commented Oct 5, 2015 syntax error Error code is as follows: at ChildProcess.exithandler (child_process.js:658:15) at ChildProcess.emit (events.js:98:17) at maybeClose (child_process.js:766:16) at Process.ChildProcess._handle.onexit (child_process.js:833:5) Error: Command failed: /home/agepath/node_modules/mean-seo/node_modules/phantomjs/lib/phantom/bin/phantomjs: 4: /home/agepath/node_modules/mean-seo/node_modules/phantomjs/lib/phantom/bin/phantomjs: Syntax error: Unterminated quoted string siboulet commented Oct 13, 2015 @seanemmer I've been using the phantomjs module inside Docker containers for months without issues. Are you sure this is unterminated quoted string not an issue with the mean-seo module you're using? Can you provide more information how to reproduce this issue using plain phantomjs? What version of phantomjs package and what version of Node are you using? What platform are you on? seanemmer commented Oct 14, 2015 @siboulet the error suggests the issue originates from the phantomjs binary - I'll try to replicate it in phantom on a standalone basis. In the meantime - here's the environment, let me know if there's any glaring issues: Node 0.12 64bit Amazon Linux 2015.03 v2.0.0 running Docker 1.6.2 (AWS Elastic Beanstalk) wilmoore commented Oct 17, 2015 I can confirm that I see the same error within a docker container built via FROM node:4.2.1: ❯ docker run --rm -it $(basename $PWD) node_modules/.bin/phantomjs --version /app/node_modules/phantomjs/lib/phantom/bin/phantomjs: 4: /app/node_modules/phantomjs/lib/phantom/bin/phantomjs: Syntax error: Unterminated quoted string siboulet commented Oct 22, 2015 @wilmoore haven't had a chance to test under 4.2.1 yet, but am not ha
Get Kubuntu Get Xubuntu Get Lubuntu Get UbuntuStudio Get Mythbuntu Get Edubuntu Get Ubuntu-GNOME Get UbuntuKylin Ubuntu Code of Conduct Ubuntu Wiki Community Wiki Other Support Launchpad Answers Ubuntu IRC Support AskUbuntu Official Documentation User Documentation Social Media Facebook Twitter Useful Links Distrowatch Bugs: Ubuntu PPAs: Ubuntu Web Upd8: Ubuntu OMG! Ubuntu Ubuntu Insights Planet Ubuntu Activity Page Please read before SSO login Advanced Search Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [ubuntu] Getting "Syntax error: Unterminated quoted string" on execution. Having an Issue With Posting ? Do you want to help us debug the posting issues ? < is the place to report it, thanks ! Results 1 to 4 of 4 Thread: Getting "Syntax error: Unterminated quoted string" on execution. Thread Tools Show Printable Version Subscribe to this Thread… Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode March 12th, 2009 #1 VotaVader View Profile View Forum Posts Private Message Just Give Me the Beans! Join Date Nov 2008 Location Chile Beans 48 DistroUbuntu 11.10 Oneiric Ocelot [SOLVED]Getting "Syntax error: Unterminated quoted string" on execution. I'm trying to configure System/161 for OS/161 (the virtual machine for a study operating system for academical purposes). Anyway, I'm following the steps provided in a course website for the installation of the program, but when I try to execute a configuration script, I get the error "Syntax error: Unterminated quoted string" independent of the arguments given. I opened the script with gedit and checked for the simplest execution but not even ./configure --help will work. Does anyone know what could be causing this problem? I've tried running it as root and as regular user. I'll post the terminal output and the code to the script: Code: pedro@pedro-laptop:~/Documents/UNSW/cs3231/sys161-1.14$ ./configure --help ./configure: 1: Syntax error: Unterminated quoted string The script: Code: #!/bin/sh # # We need the following stuff: # # 1. Source location # 2. CPU type # 3. C compiler # 4. C compiler warning options # 5. Endianness # 6. CHAR_BIT # 7. sized integer types # if [ -f doc/lamebus.html ]; then SRCDIR="" else SRCDIR=`echo "$0" | sed 's,[^/]*$,,` fi while [ "x$1" != x ]; do case "$1" in --help) cat <