Skip to content

Commit

Permalink
Merge pull request #691 from salesforcecli/mdonnalley/bump-sf-plugins…
Browse files Browse the repository at this point in the history
…-core

feat: bump sf-plugins-core
  • Loading branch information
mdonnalley authored Mar 25, 2024
2 parents 52e3e16 + 4698a8f commit 5ee220d
Show file tree
Hide file tree
Showing 6 changed files with 106 additions and 22 deletions.
92 changes: 89 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,95 @@ sfdx plugins

<!-- commands -->

# Command Topics
- [`sf doctor`](#sf-doctor)
- [`sf info releasenotes display`](#sf-info-releasenotes-display)

- [`sf doctor`](docs/doctor.md) - Tools for diagnosing problems with Salesforce CLI.
- [`sf info`](docs/info.md) - Access Salesforce CLI information from the command line.
## `sf doctor`

Gather CLI configuration data and run diagnostic tests to discover and report potential problems in your environment.

```
USAGE
$ sf doctor [--json] [--flags-dir <value>] [-c <value>] [-p <value>] [-d <value>] [-i]
FLAGS
-c, --command=<value> Command to run in debug mode; results are written to a log file.
-d, --output-dir=<value> Directory to save all created files rather than the current working directory.
-i, --create-issue Create a new issue on our GitHub repo and attach all diagnostic results.
-p, --plugin=<value> Specific plugin on which to run diagnostics.
GLOBAL FLAGS
--flags-dir=<value> Import flag values from a directory.
--json Format output as json.
DESCRIPTION
Gather CLI configuration data and run diagnostic tests to discover and report potential problems in your environment.
When you run the doctor command without parameters, it first displays a diagnostic overview of your environment. It
then writes a detailed diagnosis to a JSON file in the current directory. Use the --outputdir to specify a different
directory. To run diagnostic tests on a specific plugin, use the --plugin parameter. If the plugin isn't listening to
the doctor, then you get a warning.
Use the --command parameter to run a specific command in debug mode; the doctor writes both stdout and stderr to
\*.log files that you can provide to Salesforce Customer Support or attach to a GitHub issue.
Plugin providers can also implement their own doctor diagnostic tests by listening to the "sf-doctor" event and
running plugin specific tests that are then included in the doctor diagnostics log.
EXAMPLES
Run CLI doctor diagnostics:
$ sf doctor
Run CLI doctor diagnostics and the specified command, and write the debug output to a file:
$ sf doctor --command "force:org:list --all"
Run CLI doctor diagnostics for a specific plugin:
$ sf doctor --plugin @salesforce/plugin-source
```

_See code: [src/commands/doctor.ts](https://github.com/salesforcecli/plugin-info/blob/3.0.34/src/commands/doctor.ts)_

## `sf info releasenotes display`

Display Salesforce CLI release notes on the command line.

```
USAGE
$ sf info releasenotes display [--json] [--flags-dir <value>] [-v <value>]
FLAGS
-v, --version=<value> CLI version or tag for which to display release notes.
GLOBAL FLAGS
--flags-dir=<value> Import flag values from a directory.
--json Format output as json.
DESCRIPTION
Display Salesforce CLI release notes on the command line.
By default, this command displays release notes for the currently installed CLI version on your computer. Use the
--version flag to view release notes for a different release.
ALIASES
$ sf whatsnew
EXAMPLES
Display release notes for the currently installed CLI version:
$ sf info releasenotes display stable, stable-rc, latest, latest-rc, rc
Display release notes for CLI version 7.120.0:
$ sf info releasenotes display --version 7.120.0 stable, stable-rc, latest, latest-rc, rc
Display release notes for the CLI version that corresponds to a tag (stable, stable-rc, latest, latest-rc, rc):
$ sf info releasenotes display --version latest
```

_See code: [src/commands/info/releasenotes/display.ts](https://github.com/salesforcecli/plugin-info/blob/3.0.34/src/commands/info/releasenotes/display.ts)_

<!-- commandsstop -->
16 changes: 8 additions & 8 deletions command-snapshot.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
[
{
"command": "doctor",
"plugin": "@salesforce/plugin-info",
"flags": ["command", "create-issue", "json", "loglevel", "output-dir", "plugin"],
"alias": [],
"command": "doctor",
"flagAliases": ["createissue", "o", "outputdir"],
"flagChars": ["c", "d", "i", "p"],
"flagAliases": ["createissue", "o", "outputdir"]
"flags": ["command", "create-issue", "flags-dir", "json", "loglevel", "output-dir", "plugin"],
"plugin": "@salesforce/plugin-info"
},
{
"command": "info:releasenotes:display",
"plugin": "@salesforce/plugin-info",
"flags": ["hook", "json", "loglevel", "version"],
"alias": ["whatsnew"],
"command": "info:releasenotes:display",
"flagAliases": [],
"flagChars": ["v"],
"flagAliases": []
"flags": ["flags-dir", "hook", "json", "loglevel", "version"],
"plugin": "@salesforce/plugin-info"
}
]
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"@oclif/core": "^3.23.0",
"@salesforce/core": "^6.7.1",
"@salesforce/kit": "^3.0.15",
"@salesforce/sf-plugins-core": "^7.1.16",
"@salesforce/sf-plugins-core": "^8.0.1",
"got": "^13.0.0",
"marked": "^4.3.0",
"marked-terminal": "^4.2.0",
Expand Down
3 changes: 1 addition & 2 deletions src/commands/info/releasenotes/display.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import { EOL } from 'node:os';


import { marked } from 'marked';
import TerminalRenderer from 'marked-terminal';
import { Env } from '@salesforce/kit';
Expand All @@ -17,7 +16,7 @@ import type { AnyJson, JsonMap } from '@salesforce/ts-types';
import shared from '../../../shared/index.js';

// Initialize Messages with the current plugin directory
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url)
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);

const helpers = ['stable', 'stable-rc', 'latest', 'latest-rc', 'rc'];

Expand Down
3 changes: 1 addition & 2 deletions src/diagnostics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import childProcess from 'node:child_process';


import { Interfaces } from '@oclif/core';
import { Lifecycle, Messages } from '@salesforce/core';
import { SfDoctor, SfDoctorDiagnosis } from './doctor.js';
Expand All @@ -24,7 +23,7 @@ export interface DiagnosticStatus {
status: 'pass' | 'fail' | 'warn' | 'unknown';
}

Messages.importMessagesDirectoryFromMetaUrl(import.meta.url)
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
const messages = Messages.loadMessages('@salesforce/plugin-info', 'diagnostics');

/**
Expand Down
12 changes: 6 additions & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1416,7 +1416,7 @@
strip-ansi "6.0.1"
ts-retry-promise "^0.8.0"

"@salesforce/core@^6.4.1", "@salesforce/core@^6.5.3", "@salesforce/core@^6.6.0", "@salesforce/core@^6.7.0", "@salesforce/core@^6.7.1":
"@salesforce/core@^6.4.1", "@salesforce/core@^6.5.3", "@salesforce/core@^6.7.0", "@salesforce/core@^6.7.1", "@salesforce/core@^6.7.3":
version "6.7.3"
resolved "https://registry.yarnpkg.com/@salesforce/core/-/core-6.7.3.tgz#5d8f30c40ac3cebb898c8e845fe9a067bc729268"
integrity sha512-uU+PuZZGXxByhvnXLH1V3eY5P1caw401dIZ/QvhzYxoP/alPLk7dpChnZNJYH5Rw3dc/AhSPw+eg0cvUyjhP1Q==
Expand Down Expand Up @@ -1522,15 +1522,15 @@
chalk "^4"
inquirer "^8.2.5"

"@salesforce/sf-plugins-core@^7.1.16":
version "7.1.16"
resolved "https://registry.yarnpkg.com/@salesforce/sf-plugins-core/-/sf-plugins-core-7.1.16.tgz#a68673560f01421ac18a0bc1d4687abc35e11234"
integrity sha512-v135A7TG1n97eFoh0j96kbHKbivXbbd7M5url3L0I5lJsCGGF+mMSL2Tpm8FNUN8DCLOGkvymR1s2QmNzMR7Tw==
"@salesforce/sf-plugins-core@^8.0.1":
version "8.0.1"
resolved "https://registry.yarnpkg.com/@salesforce/sf-plugins-core/-/sf-plugins-core-8.0.1.tgz#f155cddfd7695aab0d8264848b634b2a91cdbf2c"
integrity sha512-R6SqJ1XqSINSWdZruKtC2SKGnLBh7KbFI7+qS0FYlyPU4IlWoa+AZkGwWvlczuSOumqnlhT95rNKwZTS5rJugA==
dependencies:
"@inquirer/confirm" "^2.0.17"
"@inquirer/password" "^1.1.16"
"@oclif/core" "^3.23.0"
"@salesforce/core" "^6.6.0"
"@salesforce/core" "^6.7.3"
"@salesforce/kit" "^3.0.15"
"@salesforce/ts-types" "^2.0.9"
chalk "^5.3.0"
Expand Down

0 comments on commit 5ee220d

Please sign in to comment.