List all files changed in a pull request in Git/GitHub

前端 未结 6 1722
执念已碎
执念已碎 2020-12-29 04:58

Is there a way (from the command line) to list the names of all files changed in a PR in Git/GitHub? This would be used to find what tests need to be run in a Travis CI buil

6条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-29 05:29

    For GitHub specifically, this can be accomplished using the REST API:

    GET /repos/:owner/:repo/pulls/:pull_number/files
    

    You can use one of the GitHub libraries for this purpose.

提交回复
热议问题