# mgk-dx-plugin

> Plugin for the Salesforce CLI

Latest version **1.0.4** (published 2022-05-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install mgk-dx-plugin
pnpm add mgk-dx-plugin
yarn add mgk-dx-plugin
bun add mgk-dx-plugin
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2022-05-07 |
| First published | 2021-07-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=8.0.0 |
| Dependencies | 9 |
| Unpacked size | 60.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | @scottmcclung |
| Maintainers | scottmcclung |
| Keywords | sfdx-plugin |

## Links

- npm: https://www.npmjs.com/package/mgk-dx-plugin
- Repository: https://github.com/scottmcclung/mgk-dx-plugin
- Issues: https://github.com/scottmcclung/mgk-dx-plugin/issues
- npm.io page: https://npm.io/package/mgk-dx-plugin

## Dependencies (9)

- [tslib](https://npm.io/package/tslib.md) ^1
- [exceljs](https://npm.io/package/exceljs.md) ^4.2.1
- [csv-writer](https://npm.io/package/csv-writer.md) ^1.6.0
- [@oclif/config](https://npm.io/package/@oclif/config.md) ^1
- [@oclif/errors](https://npm.io/package/@oclif/errors.md) ^1
- [@oclif/command](https://npm.io/package/@oclif/command.md) ^1
- [@salesforce/core](https://npm.io/package/@salesforce/core.md) ^2.23
- [@salesforce/command](https://npm.io/package/@salesforce/command.md) ^3.1
- [@salesforce/ts-types](https://npm.io/package/@salesforce/ts-types.md) ^1.5

## Recent versions

- 1.0.4 (latest) — 2022-05-07
- 1.0.3 — 2022-05-07
- 1.0.2 — 2022-05-07
- 1.0.1 — 2021-07-01
- 1.0.0 — 2021-07-01

## README

# mgk-dx-plugin
Plugin for the Salesforce CLI

## Features

### Schema Export
Extracts org metadata to provide a list of objects and fields in a convenient Excel report. (Field attributes include the **Description** field!)

The default behavior is to extract all standard and custom objects.  This will also include the schema for things like External Objects, Platform Events, or Custom Metadata Types.

- Use the `--customobjectsonly` flag to limit the output to just custom objects.
- Use the `-s` flag to limit the output to a specific list of objects.  `-s Account,Contact,MyCustomObject__c,MyPlatformEvent__e`


## Installation into the Salesforce CLI

Install the plugin into your Salesforce CLI using this command:

```sh-session
$ sfdx plugins:install mgk-dx-plugin
```

You can check a successful installation with `sfdx plugins`. Updates are applied when executing `sfdx plugins:update`.

## Salesforce CLI References
More information about the Salesforce CLI can be found at [https://developer.salesforce.com/tools/sfdxcli](https://developer.salesforce.com/tools/sfdxcli)
<br>
An admin focused Salesforce CLI tutorial [https://www.youtube.com/watch?v=VMU8xbmqmQ4](https://www.youtube.com/watch?v=VMU8xbmqmQ4) 


## Commands
  <!-- commands -->
* [`sfdx mgk:schema:export -f xls|csv -p <filepath> [-s <array>] [--customobjectsonly] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]`](#sfdx-mgkschemaexport--f-xlscsv--p-filepath--s-array---customobjectsonly--u-string---apiversion-string---json---loglevel-tracedebuginfowarnerrorfataltracedebuginfowarnerrorfatal)

## `sfdx mgk:schema:export -f xls|csv -p <filepath> [-s <array>] [--customobjectsonly] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]`

Exports sobject schema to various formats

```
Exports sobject schema to various formats

USAGE
  $ sfdx mgk:schema:export -f xls|csv -p <filepath> [-s <array>] [--customobjectsonly] [-u <string>] [--apiversion 
  <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

OPTIONS
  -f, --format=(xls|csv)                                                            (required) the format of the export
                                                                                    (xls, csv)

  -p, --targetpath=targetpath                                                       (required) the destination filepath

  -s, --sobjects=sobjects                                                           the named sobjects to be included in
                                                                                    the export - default is all custom
                                                                                    and standard objects are exported

  -u, --targetusername=targetusername                                               username or alias for the target
                                                                                    org; overrides default target org

  --apiversion=apiversion                                                           override the api version used for
                                                                                    api requests made by this command

  --customobjectsonly                                                               limit the report to custom objects

  --json                                                                            format output as json

  --loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL)  [default: warn] logging level for
                                                                                    this command invocation

EXAMPLES
  $ sfdx mgk:schema:export --format xls --targetpath ./dir/example-filename.xls --targetusername myOrg@example.com 
  $ sfdx mgk:schema:export --format xls --targetpath ./dir/example-filename.xls --customobjectsonly --targetusername 
  myOrg@example.com 
  $ sfdx mgk:schema:export --sobjects=Account --format xls --targetpath ./dir/example-filename.xls --targetusername 
  myOrg@example.com
  $ sfdx mgk:schema:export --sobjects=Account,Case,Opportunity,MyCustomObject__c --format xls --targetpath 
  ./dir/example-filename.xls --targetusername myOrg@example.com
```

_See code: [lib/commands/mgk/schema/export.js](https://github.com/scottmcclung/mgk-dx-plugin/blob/v1.0.4/lib/commands/mgk/schema/export.js)_
<!-- commandsstop -->

---
_Source: https://npm.io/package/mgk-dx-plugin · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
