Repository navigation
Open repositories by path, take 2 - #1924
Conversation
| { type: PopupType.MergeBranch, repository: Repository } | | ||
| { type: PopupType.RepositorySettings, repository: Repository } | | ||
| { type: PopupType.AddRepository } | | ||
| { type: PopupType.AddRepository, initialPath: string | null } | |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| const state = this.appStore.getState() | ||
| const repositories = state.repositories | ||
| const existingRepository = repositories.find(r => ( | ||
| Path.normalize(r.path) === Path.normalize(action.path) |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| interface IURLAction<T> { | ||
| name: string | ||
| readonly args: T | ||
| export interface IOpenRepositoryFromPathArgs { |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| }) | ||
|
|
||
| it('parses local paths', () => { | ||
| const path = '/Users/johnsmith/repo' |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| expect(openRepo.filepath).to.equal('Octokit.Reactive/Octokit.Reactive.csproj') | ||
| }) | ||
|
|
||
| it('parses local paths', () => { |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
|
📟 |
|
This is mergeable again 🙏 |
|
This is mergeable again 🙏 🙏 |
Part one of addressing #696
Add the ability to handle URL protocol requests that open a repository by path, e.g.,
x-github-client://openLocalRepo/ENCODED_PATH.