@sharinpix/sharinpix-sf-cli 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,145 @@
1
+ # sharinpix-sf-cli
2
+
3
+ [![NPM](https://img.shields.io/npm/v/sharinpix-sf-cli.svg?label=sharinpix-sf-cli)](https://www.npmjs.com/package/sharinpix-sf-cli) [![Downloads/week](https://img.shields.io/npm/dw/sharinpix-sf-cli.svg)](https://npmjs.org/package/sharinpix-sf-cli) [![License](https://img.shields.io/badge/License-BSD%203--Clause-brightgreen.svg)](https://raw.githubusercontent.com/salesforcecli/sharinpix-sf-cli/main/LICENSE.txt)
4
+
5
+ ## Using the template
6
+
7
+ This repository provides a template for creating a plugin for the Salesforce CLI. To convert this template to a working plugin:
8
+
9
+ 1. Please get in touch with the Platform CLI team. We want to help you develop your plugin.
10
+ 2. Generate your plugin:
11
+
12
+ ```
13
+ sf plugins install dev
14
+ sf dev generate plugin
15
+
16
+ git init -b main
17
+ git add . && git commit -m "chore: initial commit"
18
+ ```
19
+
20
+ 3. Create your plugin's repo in the salesforcecli github org
21
+ 4. When you're ready, replace the contents of this README with the information you want.
22
+
23
+ ## Learn about `sf` plugins
24
+
25
+ Salesforce CLI plugins are based on the [oclif plugin framework](<(https://oclif.io/docs/introduction.html)>). Read the [plugin developer guide](https://developer.salesforce.com/docs/atlas.en-us.sfdx_cli_plugins.meta/sfdx_cli_plugins/cli_plugins_architecture_sf_cli.htm) to learn about Salesforce CLI plugin development.
26
+
27
+ This repository contains a lot of additional scripts and tools to help with general Salesforce node development and enforce coding standards. You should familiarize yourself with some of the [node developer packages](#tooling) used by Salesforce.
28
+
29
+ Additionally, there are some additional tests that the Salesforce CLI will enforce if this plugin is ever bundled with the CLI. These test are included by default under the `posttest` script and it is required to keep these tests active in your plugin if you plan to have it bundled.
30
+
31
+ ### Tooling
32
+
33
+ - [@salesforce/core](https://github.com/forcedotcom/sfdx-core)
34
+ - [@salesforce/kit](https://github.com/forcedotcom/kit)
35
+ - [@salesforce/sf-plugins-core](https://github.com/salesforcecli/sf-plugins-core)
36
+ - [@salesforce/ts-types](https://github.com/forcedotcom/ts-types)
37
+ - [@salesforce/ts-sinon](https://github.com/forcedotcom/ts-sinon)
38
+ - [@salesforce/dev-config](https://github.com/forcedotcom/dev-config)
39
+ - [@salesforce/dev-scripts](https://github.com/forcedotcom/dev-scripts)
40
+
41
+ ### Hooks
42
+
43
+ For cross clouds commands, e.g. `sf env list`, we utilize [oclif hooks](https://oclif.io/docs/hooks) to get the relevant information from installed plugins.
44
+
45
+ This plugin includes sample hooks in the [src/hooks directory](src/hooks). You'll just need to add the appropriate logic. You can also delete any of the hooks if they aren't required for your plugin.
46
+
47
+ # Everything past here is only a suggestion as to what should be in your specific plugin's description
48
+
49
+ This plugin is bundled with the [Salesforce CLI](https://developer.salesforce.com/tools/sfdxcli). For more information on the CLI, read the [getting started guide](https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_intro.htm).
50
+
51
+ We always recommend using the latest version of these commands bundled with the CLI, however, you can install a specific version or tag if needed.
52
+
53
+ ## Install
54
+
55
+ ```bash
56
+ sf plugins install sharinpix-sf-cli@x.y.z
57
+ ```
58
+
59
+ ## Issues
60
+
61
+ Please report any issues at https://github.com/forcedotcom/cli/issues
62
+
63
+ ## Contributing
64
+
65
+ 1. Please read our [Code of Conduct](CODE_OF_CONDUCT.md)
66
+ 2. Create a new issue before starting your project so that we can keep track of
67
+ what you are trying to add/fix. That way, we can also offer suggestions or
68
+ let you know if there is already an effort in progress.
69
+ 3. Fork this repository.
70
+ 4. [Build the plugin locally](#build)
71
+ 5. Create a _topic_ branch in your fork. Note, this step is recommended but technically not required if contributing using a fork.
72
+ 6. Edit the code in your fork.
73
+ 7. Write appropriate tests for your changes. Try to achieve at least 95% code coverage on any new code. No pull request will be accepted without unit tests.
74
+ 8. Sign CLA (see [CLA](#cla) below).
75
+ 9. Send us a pull request when you are done. We'll review your code, suggest any needed changes, and merge it in.
76
+
77
+ ### CLA
78
+
79
+ External contributors will be required to sign a Contributor's License
80
+ Agreement. You can do so by going to https://cla.salesforce.com/sign-cla.
81
+
82
+ ### Build
83
+
84
+ To build the plugin locally, make sure to have yarn installed and run the following commands:
85
+
86
+ ```bash
87
+ # Clone the repository
88
+ git clone git@github.com:salesforcecli/sharinpix-sf-cli
89
+
90
+ # Install the dependencies and compile
91
+ yarn && yarn build
92
+ ```
93
+
94
+ To use your plugin, run using the local `./bin/dev` or `./bin/dev.cmd` file.
95
+
96
+ ```bash
97
+ # Run using local run file.
98
+ ./bin/dev hello world
99
+ ```
100
+
101
+ There should be no differences when running via the Salesforce CLI or using the local run file. However, it can be useful to link the plugin to do some additional testing or run your commands from anywhere on your machine.
102
+
103
+ ```bash
104
+ # Link your plugin to the sf cli
105
+ sf plugins link .
106
+ # To verify
107
+ sf plugins
108
+ ```
109
+
110
+ ## Commands
111
+
112
+ <!-- commands -->
113
+
114
+ - [`sf hello world`](#sf-hello-world)
115
+
116
+ ## `sf hello world`
117
+
118
+ Say hello either to the world or someone you know.
119
+
120
+ ```
121
+ USAGE
122
+ $ sf hello world [--json] [-n <value>]
123
+
124
+ FLAGS
125
+ -n, --name=<value> [default: World] The name of the person you'd like to say hello to.
126
+
127
+ GLOBAL FLAGS
128
+ --json Format output as json.
129
+
130
+ DESCRIPTION
131
+ Say hello either to the world or someone you know.
132
+
133
+ Say hello either to the world or someone you know.
134
+
135
+ EXAMPLES
136
+ Say hello to the world:
137
+
138
+ $ sf hello world
139
+
140
+ Say hello to someone you know:
141
+
142
+ $ sf hello world --name Astro
143
+ ```
144
+
145
+ <!-- commandsstop -->
@@ -0,0 +1,29 @@
1
+ # summary
2
+
3
+ Say hello.
4
+
5
+ # description
6
+
7
+ Say hello either to the world or someone you know.
8
+
9
+ # flags.org.summary
10
+
11
+ The name of the person you'd like to say hello to.
12
+
13
+ # flags.org.description
14
+
15
+ This person can be anyone in the world!
16
+
17
+ # examples
18
+
19
+ - Say hello to the world:
20
+
21
+ <%= config.bin %> <%= command.id %>
22
+
23
+ - Say hello to someone you know:
24
+
25
+ <%= config.bin %> <%= command.id %> --name Astro
26
+
27
+ # info.hello
28
+
29
+ Hello %s at %s
@@ -0,0 +1,19 @@
1
+ # summary
2
+
3
+ Summary of a command.
4
+
5
+ # description
6
+
7
+ More information about a command. Don't repeat the summary.
8
+
9
+ # flags.name.summary
10
+
11
+ Description of a flag.
12
+
13
+ # flags.name.description
14
+
15
+ More information about a flag. Don't repeat the summary.
16
+
17
+ # examples
18
+
19
+ - <%= config.bin %> <%= command.id %>
@@ -0,0 +1,19 @@
1
+ # summary
2
+
3
+ Summary of a command.
4
+
5
+ # description
6
+
7
+ More information about a command. Don't repeat the summary.
8
+
9
+ # flags.name.summary
10
+
11
+ Description of a flag.
12
+
13
+ # flags.name.description
14
+
15
+ More information about a flag. Don't repeat the summary.
16
+
17
+ # examples
18
+
19
+ - <%= config.bin %> <%= command.id %>