Sign In/My Account | View Cart  

advertisement

AddThis Social Bookmark Button

Article:
  Build Your Own Blogging Application, Part 2
Subject:   Script updateBlog.sh
Date:   2004-12-19 19:20:34
From:   manuelderieux
Response to: Script updateBlog.sh

I get the following errors:


./updateBlog.sh: line 13: processImages.pl: command not found
./updateBlog.sh: line 17: postEntry.pl: command not found
./updateBlog.sh: line 13: processImages.pl: command not found
./updateBlog.sh: line 17: postEntry.pl: command not found
while executing
"exec ./updateBlog.sh"
(procedure "WriteToBlog" line 7)
invoked from within
"WriteToBlog"
(procedure "WriteToBlogQuit" line 2)
invoked from within
"WriteToBlogQuit"
(menu invoke)


Here's my updateBlog.sh:


#!/bin/bash
#Glue for the perl scripts



#configuration settings
export BLOG_PATH=/Manuel
export BLOG_PAGE=sampleFormat.html
export BLOG_ENTRY=newentry



#update the image tags in file 'newentry' and
#copy the image files to the iDisk
./processImages.pl $BLOG_ENTRY $BLOG_PATH



#execute the read.pl script and pass args.
./postEntry.pl $BLOG_PATH/$BLOG_PAGE


Any help would be appreciated

Full Threads Oldest First

Showing messages 1 through 3 of 3.

  • Matthew Russell photo Script updateBlog.sh
    2004-12-19 19:32:51  Matthew Russell | O'Reilly AuthorO'Reilly Blogger [View]

    Bash is telling you that it can't find executable files by the names of processImages.pl or postEntry.pl in the current directory (the same one that updateBlog.sh is located in)

    One of three things is extremely likely:

    1) Those files are simply not in the same directory as updateBlog.sh, or

    2) You've misspelled their their names/forgot an extension, or most likely:

    3) You don't have executable permissions set on these files and therefore it can't 'find' them because they're not 'commands'. To check permissions, type 'ls -al <filename>' and make sure that you see at least one 'x' in the output. Do a 'man ls' for more info on exactly what the output means.

    Let me know how it goes.
    Matthew
    • Script updateBlog.sh
      2004-12-20 07:50:40  manuelderieux [View]

      Your points 2 & 3 were my downfall, it's part of the arrogance of considering myself precise.

      Thank you.
      • Matthew Russell photo Script updateBlog.sh
        2004-12-20 07:54:43  Matthew Russell | O'Reilly AuthorO'Reilly Blogger [View]

        No sweat. We've all done it and are bound to do it again. Path and permissions related issues are probably 90% of the problems I've ever had to work through.

        Matthew