From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29981 invoked by alias); 1 Nov 2013 05:59:37 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 18086 Received: (qmail 15039 invoked from network); 1 Nov 2013 05:59:33 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=A0rOohRL1BsR+9BQmHSInkLOvhh0r/GloRyDyyUQeCY=; b=aNktjPm32xIEHjK9qGDmP7blQDQ/WlLHR46GzHb1FkVNV8b3TDJSc1Brxwi/td3427 9zMhbNRWmN1+pa6BQsEgB3xkmCPHYBd8etSZAWgR01birDcEmSbEMqf8VmwF+VymraBg Bn/Ux+qK2BYVY5k0TQka1ldBAWEThHPPjpvlhxq/G55NcJEGMG4PLDi8ABNs6CdFzLt1 MybLYhTfRZSpo5XivyxDzezLezA5iIKlCmYkmHFI2xxiautWh/l6qZEX02F+wZuPSkcH tAcaKUGz++Ccy0QnPzmlECoJCCGuTL+opFxzjmGVc4DC8hjBS+s30gmpAVGQgYpb9Si2 HZXg== X-Received: by 10.224.25.8 with SMTP id x8mr1654768qab.77.1383285568053; Thu, 31 Oct 2013 22:59:28 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: From: TJ Luoma Date: Fri, 1 Nov 2013 01:58:47 -0400 Message-ID: Subject: Re: How to parse JavaScript from Zsh? To: Thiago Padilha Cc: Zsh-Users List Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Thu, Oct 31, 2013 at 10:59 PM, Thiago Padilha wro= te: > Perhaps they are sending just JSON and you mistake with javascript? If it= s > just json you can try this https://github.com/micha/jsawk it targets bash > but should work with zsh. Well, this sent me back looking more closely at it=E2=80=A6 yes, it was javascript=E2=80=A6 but the good news is that when I started poking around = I found that the information I wanted was being pulled (via JS) from a regular HTML page. So now I'm just parsing that using curl, sed, and tr. (You can even see it at https://gist.github.com/tjluoma/7260924 if you want, but I warn you: it's ugly. But it works.) Thanks! TjL