rabobank / ret-plugins Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
As I am creating the GitHub implementation, I'm finding multiple flaws in the current interfaces which makes certain things impossible.
Therefor I would like to propose some changes. I figured this could be a place for discussion.
In my opinion we can already merge the first PR (decouple from Azure DevOps) whenever you approve, and then we can follow it up with one that contains the outcome of this discussion. I think it will keep the changes clearer and the PRs smaller.
I've checked which current interface methods are compatible with GitHub and which aren't. I've added proposed solutions for the latter. At the bottom I've wrote down what I think about how to handle singular versus multiple Git implementations.
Method | Compatible | Notes | Proposal |
---|---|---|---|
getAllPullRequests() |
Yes | - | |
getPullRequestsNotReviewedByUser() |
Kind of | By looking up all pull requests, followed by specific api calls per PR. n+1 | Not support this in GH (the -n flag in git-pullrequest) |
getPullRequestById(id) |
No | A repository name is required here | PRs should always be tied to repositories, so make it getPullRequestById(repository: String, id) |
createPullRequest(repository, sourceRefName, targetRefName, title, description) |
? | TBD | |
getAllRepositories() |
Yes | - | |
getRepositoryById(repository) |
Yes | - | |
getAllRefs(repository, filter) |
Yes | We only use this to get all branches. In AzDo you can only do this using the getRefs API and filtering on "heads/". This is AzDo functionality, so should be in the AzDo provider. | Rename to getAllBranches(repository) |
getAllPipelines() |
Kind of | We could loop through all repositories then fetch their pipelines, n+1 requests | Not support this, but introduce an optional repository: String? parameter |
getPipelineRuns(pipelineId) |
No | Pipelines are tied to repositories | Not support this, but introduce an optional repository: String? parameter |
Method | Compatible | Notes | Proposal |
---|---|---|---|
repository(name) |
Yes | - | |
pipelineRun(id) |
No | Pipelines are tied to repositories | Introduce repository: String? param |
pipeline(id) |
No | Pipelines are tied to repositories. | Introduce repository: String? param |
pipelineDashboard() |
No | There is no project-wide pipeline dashboard | Don't support this, or perhaps introduce the repository: String? parameter (would enable users to go to the pipeline dashboard of their context-aware project for example) |
pullRequest(repositoryName, id) |
Yes | - | |
pullRequestCreate(repositoryName, sourceRef) |
Yes | - |
In general I think that for most of the list commands (autocompletion) we should combine the results of both GitProviders (if they are configured).
For actions (create PR, open URL), we should of course open the target from the right GitProvider. For this, we would need to improve the autogeneration keys
to include the git provider and the repository name: ret git pr open github/users-api/136274
If at a later stage we would support multiple implementations per provider, we could extend this to github/<org>/users-api/136274
.
Currently it's only possible to add projects to the Splunk plugin's configuration by hand. There is also no link between an index and a project.
{
"base_url" : "https://where.splunk.lives",
"app" : "app",
"indexes" : "index1, index2",
"search_field" : "app-name",
"projects" : [ {
"name" : "project-1"
}, {
"name" : "project-2"
} ],
"plugin_version" : "0.2.0"
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.