Code Monkey home page Code Monkey logo

Comments (4)

sorenlouv avatar sorenlouv commented on May 25, 2024 1

PRs are very welcome.

from backport.

sorenlouv avatar sorenlouv commented on May 25, 2024

Hi CJ,

I don't know a lot about Github Enterprise, but happy to support it!
Afaict github.com is currently hardcoded in calls to Github's API and in the git url.

Calls to Github's API
https://github.com/sqren/backport/blob/493aefbdee393a05ac3e22e9aceea127f1637de5/src/services/github.ts#L46-L49

Calls to the API are prefixed with https://api.github.com/. Would it be sufficient to just being able to replace the hostname part: https://api.${githubHost}/ where githubHost defaults to github.com ?

Git url
https://github.com/sqren/backport/blob/fce7a4f4f3737cd63214813749398de8fe4415fe/src/services/git.ts#L42-L52

The git remote url currently looks like: https://${accessToken}@github.com/${owner}/${repoName}.git. Would this be sufficient:
https://${accessToken}@${githubHost}/${owner}/${repoName}.git?

If that's the case, it should be fairly simple to allow the end user to add githubHost to either of the configs (.backportrc.json, .backport/config.json) or via cli --githubHost=customDomain.com.

from backport.

cjskillingstad avatar cjskillingstad commented on May 25, 2024

@sqren This looks like exactly what I was thinking. More than happy to submit a PR

from backport.

sorenlouv avatar sorenlouv commented on May 25, 2024

Resolved in #129

from backport.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.