Bladeren bron

Add possibility to disable all welcome screens. Fixes #1049. (#1258)

main
Rickard 4 jaren geleden
committed by GitHub
bovenliggende
commit
b30f4bcf0d
Geen bekende sleutel gevonden voor deze handtekening in de database GPG sleutel-ID: 4AEE18F83AFDEB23
4 gewijzigde bestanden met toevoegingen van 15 en 3 verwijderingen
  1. +2
    -1
      README.md
  2. +8
    -2
      package.json
  3. +1
    -0
      src/config.ts
  4. +4
    -0
      src/extension.ts

+ 2
- 1
README.md Bestand weergeven

@ -903,7 +903,8 @@ See also [View Settings](#view-settings- 'Jump to the View settings')
| `gitlens.insiders` | Specifies whether to enable experimental features |
| `gitlens.liveshare.allowGuestAccess` | Specifies whether to allow guest access to GitLens features when using Visual Studio Live Share |
| `gitlens.outputLevel` | Specifies how much (if any) output will be sent to the GitLens output channel |
| `gitlens.showWhatsNewAfterUpgrades` | Specifies whether to show What's New after upgrading to new feature releases |
| `gitlens.showWelcomeOrWhatsNew` | Specifies whether to show the Welcome (Quick Setup) experience on first install, or the What's New notification after upgrading to new feature releases |
| `gitlens.showWhatsNewAfterUpgrades` | Specifies whether to show the What's New notification after upgrading to new feature releases |
| `gitlens.advanced.abbreviatedShaLength` | Specifies the length of abbreviated commit SHAs (shas) |
| `gitlens.advanced.blame.customArguments` | Specifies additional arguments to pass to the `git blame` command |
| `gitlens.advanced.blame.delayAfterEdit` | Specifies the time (in milliseconds) to wait before re-blaming an unsaved document after an edit. Use 0 to specify an infinite wait |

+ 8
- 2
package.json Bestand weergeven

@ -1463,10 +1463,16 @@
"markdownDescription": "Specifies user-defined remote (code-hosting) services or custom domains for built-in remote services",
"scope": "resource"
},
"gitlens.showWelcomeOrWhatsNew": {
"type": "boolean",
"default": true,
"markdownDescription": "Specifies whether to show the Welcome (Quick Setup) experience on first install, or the What's New notification after upgrading to new feature releases",
"scope": "window"
},
"gitlens.showWhatsNewAfterUpgrades": {
"type": "boolean",
"default": true,
"markdownDescription": "Specifies whether to show What's New after upgrading to new feature releases",
"markdownDescription": "Specifies whether to show the What's New notification after upgrading to new feature releases",
"scope": "window"
},
"gitlens.sortBranchesBy": {
@ -2600,7 +2606,7 @@
},
{
"command": "gitlens.showWelcomePage",
"title": "Welcome",
"title": "Welcome (Quick Setup)",
"category": "GitLens"
},
{

+ 1
- 0
src/config.ts Bestand weergeven

@ -108,6 +108,7 @@ export interface Config {
modes: Record<string, ModeConfig>;
outputLevel: TraceLevel;
remotes: RemotesConfig[] | null;
showWelcomeOrWhatsNew: boolean;
showWhatsNewAfterUpgrades: boolean;
sortBranchesBy: BranchSorting;
sortTagsBy: TagSorting;

+ 4
- 0
src/extension.ts Bestand weergeven

@ -198,6 +198,8 @@ export function notifyOnUnsupportedGitVersion(version: string) {
async function showWelcomeOrWhatsNew(version: string, previousVersion: string | undefined) {
if (previousVersion == null) {
Logger.log('GitLens first-time install');
if (!Container.config.showWelcomeOrWhatsNew) return;
await commands.executeCommand(Commands.ShowWelcomePage);
return;
@ -207,6 +209,8 @@ async function showWelcomeOrWhatsNew(version: string, previousVersion: string |
Logger.log(`GitLens upgraded from v${previousVersion} to v${version}`);
}
if (!Container.config.showWelcomeOrWhatsNew) return;
const [major, minor] = version.split('.').map(v => parseInt(v, 10));
const [prevMajor, prevMinor] = previousVersion.split('.').map(v => parseInt(v, 10));
if (

Laden…
Annuleren
Opslaan