Selaa lähdekoodia

Adds better messaging while still discovering

main
Eric Amodio 1 vuosi sitten
vanhempi
commit
d909e2b70c
7 muutettua tiedostoa jossa 21 lisäystä ja 7 poistoa
  1. +3
    -1
      src/views/branchesView.ts
  2. +3
    -1
      src/views/commitsView.ts
  3. +3
    -1
      src/views/contributorsView.ts
  4. +3
    -1
      src/views/remotesView.ts
  5. +3
    -1
      src/views/stashesView.ts
  6. +3
    -1
      src/views/tagsView.ts
  7. +3
    -1
      src/views/worktreesView.ts

+ 3
- 1
src/views/branchesView.ts Näytä tiedosto

@ -50,7 +50,9 @@ export class BranchesViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No branches could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading branches...'
: 'No branches could be found.';
return []; return [];
} }

+ 3
- 1
src/views/commitsView.ts Näytä tiedosto

@ -122,7 +122,9 @@ export class CommitsViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No commits could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading commits...'
: 'No commits could be found.';
return []; return [];
} }

+ 3
- 1
src/views/contributorsView.ts Näytä tiedosto

@ -53,7 +53,9 @@ export class ContributorsViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No contributors could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading contributors...'
: 'No contributors could be found.';
return []; return [];
} }

+ 3
- 1
src/views/remotesView.ts Näytä tiedosto

@ -51,7 +51,9 @@ export class RemotesViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No remotes could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading remotes...'
: 'No remotes could be found.';
return []; return [];
} }

+ 3
- 1
src/views/stashesView.ts Näytä tiedosto

@ -37,7 +37,9 @@ export class StashesViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No stashes could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading stashes...'
: 'No stashes could be found.';
return []; return [];
} }

+ 3
- 1
src/views/tagsView.ts Näytä tiedosto

@ -38,7 +38,9 @@ export class TagsViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No tags could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading tags...'
: 'No tags could be found.';
return []; return [];
} }

+ 3
- 1
src/views/worktreesView.ts Näytä tiedosto

@ -48,7 +48,9 @@ export class WorktreesViewNode extends RepositoriesSubscribeableNode
if (this.children == null) { if (this.children == null) {
const repositories = this.view.container.git.openRepositories; const repositories = this.view.container.git.openRepositories;
if (repositories.length === 0) { if (repositories.length === 0) {
this.view.message = 'No worktrees could be found.';
this.view.message = this.view.container.git.isDiscoveringRepositories
? 'Loading worktrees...'
: 'No worktrees could be found.';
return []; return [];
} }

Ladataan…
Peruuta
Tallenna