curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: How do I read the rest of this web site?

From: ToddAndMargo via curl-users <curl-users_at_lists.haxx.se>
Date: Fri, 16 Sep 2022 17:04:30 -0700

On 9/16/22 15:45, Ray Satiro via curl-users wrote:
> On 9/16/2022 3:45 PM, ToddAndMargo via curl-users wrote:
>> Fedora 36
>> curl-7.82.0-7.fc36.x86_64
>>
>> On the following web site
>>
>> https://github.com/nxadm/rakudo-pkg/releases
>> view-source:https://github.com/nxadm/rakudo-pkg/releases
>>
>> There is a button called "Show all 50 assets".
>>
>> <button type="button" data-view-component="true"
>> class="js-release-asset-untruncate-btn btn-link">    Show all 50 assets
>>
>> But I can not get this extra list with curl -- only
>> with Firefox.  And when I click on it with Firefox,
>> the URL does not change.
>>
>> What am I doing wrong?
>
>
> It's javascript that retrieves a separate html page [1] with all the
> assets. Also you can see all the assets on the release page for that tag
> [2]. If I were you I would parse the json from github's api [3] instead
> of trying to parse the html.
>
> curl -fLsS
> "https://api.github.com/repos/nxadm/rakudo-pkg/releases/latest" | jq
> --raw-output ".id | select(type == \"number\")"
>
> curl -fLsS
> "https://api.github.com/repos/nxadm/rakudo-pkg/releases/68967516/assets"
> | jq ".[].browser_download_url | select(type == \"string\")"
>
> [1]: https://github.com/nxadm/rakudo-pkg/releases/expanded_assets/v2022.06
> [2]: https://github.com/nxadm/rakudo-pkg/releases/v2022.06
> [3]: https://docs.github.com/en/rest/releases/assets
>

Thank you!

I did figure out a way around it.



--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Computers are like air conditioners.
They malfunction when you open windows
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-users
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2022-09-17