Skip to content

sd_utils.github.fileio

pencil-pusher edited this page Apr 19, 2021 · 3 revisions

Table of Contents

sd_utils.github.fileio

API for accessing files from github

get_file

get_file(owner: str, repo: str, file_path: str, token: str = "") -> str

Gets a file from a repo

Arguments:

  • owner str - the owner of the repo
  • repo str - the name of the repo
  • file_path str - the path of the file relative to the root of the repo
  • token str - the github token used to authenticate. failure to provide one can result in rate limits or no access to a private repo
Clone this wiki locally