[all-commits] [llvm/llvm-project] a39a28: [GitHub] Add --fail to curl commands (#72238)

David Spickett via All-commits all-commits at lists.llvm.org
Tue Nov 14 06:24:37 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a39a28d2ea3053fb6cc524b8aec871015f3940b2
      https://github.com/llvm/llvm-project/commit/a39a28d2ea3053fb6cc524b8aec871015f3940b2
  Author: David Spickett <david.spickett at linaro.org>
  Date:   2023-11-14 (Tue, 14 Nov 2023)

  Changed paths:
    M .github/workflows/issue-subscriber.yml
    M .github/workflows/pr-subscriber.yml

  Log Message:
  -----------
  [GitHub] Add --fail to curl commands (#72238)

This means that if we try to download a missing file, we do not get a
document with the same file name, but containing only the http response
code.

```
$ curl -O -L --fail https://raw.githubusercontent.com/llvm/llvm-project/main/.github/workflows/not-a-file.py
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
curl: (22) The requested URL returned error: 404
$ $?
22: command not found
```

Which will be less confusing than python complaining about the file
contents.




More information about the All-commits mailing list