Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-42270

GithubSCMFile should expose file attributes exposed by GitHub api

XMLWordPrintable

      GitHubSCMFile does not expose attributes that GitHub content API provides via it's API. Some of these are important in order to use it to talk to GitHub APIs. For example pipeline editor can only update Jenkinsfile on Github if it has access to 'sha' of the file.

      Its also good idea to expose whats coming from GitHub over to consumer. Most these attributes are already present in GHContent wrapped inside GitHubSCMFile, its matter of exposing these attributes.

      • sha - we need to to use GitHub content API to update Jenkinsfile from pipeline editor
      • size - good to have it known to client
      • encodedContent - File content should be encoded, for example if its binary file. Github by default gives base64 encoded content
      • encoding - GitHub API by default does base64 encoding
      • path - file path relative to root
      • name - name of this file

            Unassigned Unassigned
            vivek Vivek Pandey
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: