Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use gh api instead of curl for direct GitHub API queries #202

Merged
merged 2 commits into from
May 21, 2024

Conversation

jwodder
Copy link
Member

@jwodder jwodder commented May 20, 2024

No description provided.

@jwodder jwodder added the tooling Scripts used in building git-annex label May 20, 2024
@jwodder jwodder requested a review from yarikoptic May 20, 2024 12:22
@yarikoptic
Copy link
Member

windows might need special attention... so is leading / generally omittable?

Run if [ "release" = "release" ]; then
  if [ "release" = "release" ]; then
    commitish="$(gh api --jq .tag_name /repos/datalad/datalad/releases/latest)"
  else
    commitish="release"
  fi
  python -m pip install --upgrade pip
  pip install git+https://github.com/datalad/datalad@${commitish}
  shell: C:\Program Files\Git\bin\bash.EXE --noprofile --norc -e -o pipefail {0}
  env:
    LANG: C.utf-8
    DATALAD_TESTS_SSH: 1
    pythonLocation: C:\hostedtoolcache\windows\Python\3.8.10\x64
    PKG_CONFIG_PATH: C:\hostedtoolcache\windows\Python\3.8.10\x64/lib/pkgconfig
    Python_ROOT_DIR: C:\hostedtoolcache\windows\Python\3.8.10\x64
    Python[2](https://github.com/datalad/git-annex/actions/runs/9158606331/job/25177694459?pr=202#step:18:2)_ROOT_DIR: C:\hostedtoolcache\windows\Python\[3](https://github.com/datalad/git-annex/actions/runs/9158606331/job/25177694459?pr=202#step:18:3).8.10\x64
    Python3_ROOT_DIR: C:\hostedtoolcache\windows\Python\3.8.10\x6[4](https://github.com/datalad/git-annex/actions/runs/9158606331/job/25177694459?pr=202#step:18:4)
    GITHUB_TOKEN: ***
invalid API endpoint: "C:/Program Files/Git/repos/datalad/datalad/releases/latest". Your shell might be rewriting URL paths as filesystem paths. To avoid this, omit the leading slash from the endpoint argument
Error: Process completed with exit code 1.

@jwodder
Copy link
Member Author

jwodder commented May 20, 2024

Wow, Windows is truly a colossal dumpster fire of an OS.

Addressed.

@yarikoptic yarikoptic merged commit 34e5dde into master May 21, 2024
26 checks passed
@yarikoptic yarikoptic deleted the no-api-query branch May 21, 2024 13:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tooling Scripts used in building git-annex
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants