Professional Web Applications Themes

Best Newsgroup for Terminal Script Questions? - Mac Applications & Software

In comp.sys.mac.system [email]JHawkinshumanitiessoftware.com[/email] wrote: > Hi, > Is there a better newsgroup for terminal scripting, or are such posts > welcome here? Well, theres comp.unix.shell but if your question has a Mac slant at all, there are quite a few gurus around here too. -- *--------------------------------------------------------* | ^Nothing is foolproof to a sufficiently talented fool^ | | Heath Raftery, HRSoftWorks _\|/_ | *______________________________________m_('.')_m__ _______*...

  1. #1

    Default Re: Best Newsgroup for Terminal Script Questions?

    In comp.sys.mac.system [email]JHawkinshumanitiessoftware.com[/email] wrote:
    > Hi,
    > Is there a better newsgroup for terminal scripting, or are such posts
    > welcome here?
    Well, theres comp.unix.shell but if your question has a Mac slant at
    all, there are quite a few gurus around here too.

    --
    *--------------------------------------------------------*
    | ^Nothing is foolproof to a sufficiently talented fool^ |
    | Heath Raftery, HRSoftWorks _\|/_ |
    *______________________________________m_('.')_m__ _______*
    Heath Raftery Guest

  2. #2

    Default Re: Best Newsgroup for Terminal Script Questions?

    In comp.sys.mac.misc Heath Raftery <hrafterymyrealbox.com> wrote:
    >In comp.sys.mac.system [email]JHawkinshumanitiessoftware.com[/email] wrote:
    >> Hi,
    >> Is there a better newsgroup for terminal scripting, or are such posts
    >> welcome here?
    >Well, theres comp.unix.shell but if your question has a Mac slant at
    >all, there are quite a few gurus around here too.
    And c.u.s tends toward the advanced and esoteric - not always, of course, but
    I would think a Macish person wanting to get started with Terminal scripting might
    be happier right here, at least to start. Not that he shouldn't READ c.u.s of
    course.

    For some of my horribly biased thoughts on scripting, see
    [url]http://aplawrence.com/MacOSX/macosxshell.html[/url]

    --
    [email]tonyaplawrence.com[/email] Unix/Linux/Mac OS X resources: [url]http://aplawrence.com[/url]
    Get paid for writing about tech: [url]http://aplawrence.com/publish.html[/url]
    tony@aplawrence.com Guest

  3. #3

    Default Re: Best Newsgroup for Terminal Script Questions?

    Entity [email]tonyaplawrence.com[/email] spoke thus:
    > [url]http://aplawrence.com/MacOSX/macosxshell.html[/url]
    Tony, I garts a question.

    If I set my shell to bash like you recommend will my Applescripts/shell
    scripts still run like they do in tcsh?

    Or would I need to modify the script?

    --Gnarlie

    Gnarlodious Guest

  4. #4

    Default Re: Best Newsgroup for Terminal Script Questions?

    In article <70eb11538289a847209f5e912a0edd67TeraNews>,
    Gnarlodious <gnarlodiousNULLVOID.invalid.> wrote:

    :> Entity [email]tonyaplawrence.com[/email] spoke thus:
    :>
    :> > [url]http://aplawrence.com/MacOSX/macosxshell.html[/url]
    :>
    :> Tony, I garts a question.
    :>
    :> If I set my shell to bash like you recommend will my Applescripts/shell
    :> scripts still run like they do in tcsh?
    :>
    :> Or would I need to modify the script?
    :>
    :> --Gnarlie
    :>

    So far as I'm aware, AppleScripts aren't in any way be affected by
    whatever shell you use.

    As to shell scripts themselves, they will run in the shell that's
    running *unless* you tell them otherwise. That's why you should ALWAYS
    make a habit of specifying the shell that a script should use inside the
    script itself.

    By convention, it's done on the very first line of the file. If you
    want a script to run in tcsh (for example, if its syntax relies on that
    shell), you should tell it so by making the very first line read as
    follows:

    #!/bin/tcsh

    And you should always provide the full path (typically /bin) of the
    shell. Of course, if you plan to share the script, you shouldn't
    specify a shell that's not present on their system.

    = Steve =
    --
    Steve W. Jackson
    Montgomery, Alabama
    Steve W. Jackson Guest

  5. #5

    Default Re: Best Newsgroup for Terminal Script Questions?

    Entity Steve W. Jackson spoke thus:
    > :>I garts a question.
    > :> If I set my shell to bash like you recommend will my Applescripts/shell
    > :> scripts still run like they do in tcsh?
    > :>
    > :> Or would I need to modify the script?
    >
    > So far as I'm aware, AppleScripts aren't in any way be affected by
    > whatever shell you use.
    >
    > As to shell scripts themselves, they will run in the shell that's
    > running *unless* you tell them otherwise.
    As an example(snippet returns name of default browser) :
    word -1 of (do shell script "defaults read com.apple.LaunchServices | grep
    -C5 E:html | grep -w LSBundleSignature")

    This line doesn't specify a shell name, will it still run if I change the
    shell to bash?

    --Gnarlie

    Gnarlodious Guest

  6. #6

    Default Re: Best Newsgroup for Terminal Script Questions?

    <JHawkinsHumanitiesSoftware.Com> wrote:
    > Hi,
    >
    > Is there a better newsgroup for terminal scripting, or are such posts
    > welcome here?
    >
    > Thanks!
    <groan> spare us the unix-gobbledegook!
    I'm sure there are plenty of unix-NGs out there.

    --
    madiba
    madiba Guest

  7. #7

    Default Re: Best Newsgroup for Terminal Script Questions?

    In comp.sys.mac.misc madiba <downthekraal.com> wrote:
    ><JHawkinsHumanitiesSoftware.Com> wrote:
    >> Hi,
    >>
    >> Is there a better newsgroup for terminal scripting, or are such posts
    >> welcome here?
    >>
    >> Thanks!
    ><groan> spare us the unix-gobbledegook!
    As opposed to the Applescript gobbledegook?

    The "Unix goobledegook" is often a very easy and efficient way to do things that would
    otherwise take considerable effort, resources and/or time.

    Stop thinking of Terminal as some awful burden. It's a tool, and it can be very useful.

    --
    [email]tonyaplawrence.com[/email] Unix/Linux/Mac OS X resources: [url]http://aplawrence.com[/url]
    Get paid for writing about tech: [url]http://aplawrence.com/publish.html[/url]
    tony@aplawrence.com Guest

  8. #8

    Default Re: Best Newsgroup for Terminal Script Questions?

    Gnarlodious <gnarlodiousNULLVOID.invalid.> wrote in comp.sys.mac.system:
    > Entity Steve W. Jackson spoke thus:
    >
    > > :>I garts a question.
    > > :> If I set my shell to bash like you recommend will my Applescripts/shell
    > > :> scripts still run like they do in tcsh?
    > > :>
    > > :> Or would I need to modify the script?
    > >
    > > So far as I'm aware, AppleScripts aren't in any way be affected by
    > > whatever shell you use.
    > >
    > > As to shell scripts themselves, they will run in the shell that's
    > > running *unless* you tell them otherwise.
    > As an example(snippet returns name of default browser) :
    > word -1 of (do shell script "defaults read com.apple.LaunchServices | grep
    > -C5 E:html | grep -w LSBundleSignature")
    >
    > This line doesn't specify a shell name, will it still run if I change the
    > shell to bash?
    Yes, it will. AppleScript uses /bin/sh for "do shell script", no matter
    what your default shell is. (If you look closely, you will probably
    find that the binaries for sh and bash are identical. They just behave
    a bit differently, depending on the call name).

    On the other hand, it looks like a bit of overkill to employ *two*
    scripting languages to extract that bit of information, not to mention
    that the way you grep for the relevant parts is far from robust. Can't
    AppleScript access the defaults directly?

    Anno
    Anno Siegel Guest

  9. #9

    Default Re: Best Newsgroup for Terminal Script Questions?

    [email]tonyaplawrence.com[/email] writes:
    > ><JHawkinsHumanitiesSoftware.Com> wrote:
    > >> Is there a better newsgroup for terminal scripting, or are such
    > >> posts welcome here?
    > ><groan> spare us the unix-gobbledegook!
    > Stop thinking of Terminal as some awful burden. It's a tool, and it
    > can be very useful.
    Moreover, there are absolutely Mac-specific issues with
    the terminal and command line which are appropriate in
    mac newsgroups and nowhere else - like dealing with
    resource forks and application bundles. Even the fact
    of the filesystem being case-insensitive makes OS X unix
    rather different from the majority of unices out there.
    There's also the line-endings issue, too.



    --
    Plain Bread alone for e-mail, thanks. The rest gets trashed.
    No HTML in E-Mail! -- [url]http://www.expita.com/nomime.html[/url]
    Are you posting responses that are easy for others to follow?
    [url]http://www.greenend.org.uk/rjk/2000/06/14/quoting[/url]
    BreadWithSpam@fractious.net Guest

  10. #10

    Default Re: Best Newsgroup for Terminal Script Questions?

    In article <1fy35na.1759ygobj3cw5N%downthekraal.com>,
    [email]downthekraal.com[/email] (madiba) wrote:

    :> <JHawkinsHumanitiesSoftware.Com> wrote:
    :>
    :> > Hi,
    :> >
    :> > Is there a better newsgroup for terminal scripting, or are such posts
    :> > welcome here?
    :> >
    :> > Thanks!
    :> <groan> spare us the unix-gobbledegook!
    :> I'm sure there are plenty of unix-NGs out there.

    Like it or not, it's a valid Mac subject in Mac groups. I for one
    (despite being very Unix-literate) wouldn't likely be looking at Unix
    gruops for info on using my Mac.

    = Steve =
    --
    Steve W. Jackson
    Montgomery, Alabama
    Steve W. Jackson Guest

  11. #11

    Default Re: Best Newsgroup for Terminal Script Questions?


    <BreadWithSpamfractious.net> wrote in message
    news:yoby8z19ra9.fsfpanix2.panix.com...
    <CUT>
    > Even the fact
    > of the filesystem being case-insensitive makes OS X unix
    > rather different from the majority of unices out there.
    Thanks for the input. Just FYI on this point though, the Mac OS X files
    system IS case-sensitive. The Finder handles translating the case for
    anything that has to go deeper. However if you are in the terminal, you do
    have to be aware of case.

    Cheers!


    Jeff Hawkins Guest

  12. #12

    Default Re: Best Newsgroup for Terminal Script Questions?

    In article <vh6mghqjg175c1corp.supernews.com>, Jeff Hawkins
    <JHawkinsGorge.Net> wrote:
    > <BreadWithSpamfractious.net> wrote in message
    > news:yoby8z19ra9.fsfpanix2.panix.com...
    > <CUT>
    > > Even the fact
    > > of the filesystem being case-insensitive makes OS X unix
    > > rather different from the majority of unices out there.
    >
    > Thanks for the input. Just FYI on this point though, the Mac OS X files
    > system IS case-sensitive. The Finder handles translating the case for
    > anything that has to go deeper. However if you are in the terminal, you do
    > have to be aware of case.
    In some cases you do, but for many things you don't.

    --
    Jerry Kindall, Seattle, WA <http://www.jerrykindall.com/>

    When replying by e-mail, use plain text ONLY to make sure I read it.
    Due to spam and viruses, I filter all mail with HTML or attachments.
    Jerry Kindall Guest

Similar Threads

  1. More Appropriate Newsgroup
    By mcp6453 in forum Adobe Illustrator Windows
    Replies: 0
    Last Post: August 5th, 11:28 AM
  2. Replies: 0
    Last Post: July 1st, 02:04 PM
  3. Forum to OE Newsgroup
    By Chris Cox in forum Adobe Photoshop 7, CS, CS2 & CS3
    Replies: 5
    Last Post: August 7th, 08:33 AM
  4. Newsgroup respondents
    By Mike Brannigan [MSFT] in forum Windows XP/2000/ME
    Replies: 1
    Last Post: July 19th, 02:14 PM
  5. newsgroup ot
    By cmosser in forum PHP Development
    Replies: 1
    Last Post: June 30th, 05:38 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139