Skip to content

Commit 598ff29

Browse files
fix: add command files, test files, message files, remove template
1 parent 7d5025d commit 598ff29

File tree

13 files changed

+37
-247
lines changed

13 files changed

+37
-247
lines changed

README.md

Lines changed: 7 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,8 @@
1-
# plugin-<REPLACE ME>
1+
# plugin-source
22

3-
Change above to <REPLACE_ME> before finalizing
3+
# This plugin is under heavy development and does NOT currently have feature parity
44

5-
&lt;REPLACE ME DESCRIPTION START&gt;
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. Clone this repo
10-
2. Delete the .git folder
11-
3. Replace filler values
12-
a) Every instance of `<REPLACE_ME>` can be directly substitued for the name of the new plugin. However beware, things like github paths are for the salesforcecli Github organization
13-
b) Search for case-matching `REPLACE` to find other filler values, such as for the plugin description
14-
4. Use `git init` to set up the desired git information
15-
5. Follow the getting started steps below until the `sfdx hello:org` commmand is functioning
16-
17-
&lt;REPLACE ME DESCRIPTION END&gt;
18-
19-
## Learn about the plugin-template
20-
21-
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.
22-
23-
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](https://github.com/forcedotcom/sfdx-dev-packages/) used by Salesforce. There is also a default circleci config using the [release management orb](https://github.com/forcedotcom/npm-release-management-orb) standards.
24-
25-
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 recommended to keep these tests active in your plugin, regardless if you plan to have it bundled.
26-
27-
# Everything past here is only a suggestion as to what should be in your specific plugin's description
5+
Source commands for Salesforce CLI
286

297
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).
308

@@ -33,7 +11,7 @@ We always recommend using the latest version of these commands bundled with the
3311
## Install
3412

3513
```bash
36-
sfdx plugins:install <REPLACE_ME>@x.y.z
14+
sfdx plugins:install source@x.y.z
3715
```
3816

3917
## Issues
@@ -65,7 +43,7 @@ To build the plugin locally, make sure to have yarn installed and run the follow
6543

6644
```bash
6745
# Clone the repository
68-
git clone [email protected]:salesforcecli/plugin-<REPLACE_ME>
46+
git clone [email protected]:salesforcecli/plugin-source
6947

7048
# Install the dependencies and compile
7149
yarn install
@@ -76,7 +54,7 @@ To use your plugin, run using the local `./bin/run` or `./bin/run.cmd` file.
7654

7755
```bash
7856
# Run using local run file.
79-
./bin/run <REPLACE_ME>
57+
./bin/run source:
8058
```
8159

8260
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.
@@ -88,46 +66,4 @@ sfdx plugins:link .
8866
sfdx plugins
8967
```
9068

91-
## Commands
92-
93-
<!-- commands -->
94-
95-
- [`sfdx hello:org [-n <string>] [-f] [-v <string>] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]`](#sfdx-helloorg--n-string--f--v-string--u-string---apiversion-string---json---loglevel-tracedebuginfowarnerrorfataltracedebuginfowarnerrorfatal)
96-
97-
## `sfdx hello:org [-n <string>] [-f] [-v <string>] [-u <string>] [--apiversion <string>] [--json] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]`
98-
99-
print a greeting and your org IDs
100-
101-
```
102-
USAGE
103-
$ sfdx hello:org [-n <string>] [-f] [-v <string>] [-u <string>] [--apiversion <string>] [--json] [--loglevel
104-
trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]
105-
106-
OPTIONS
107-
-f, --force example boolean flag
108-
-n, --name=name name to print
109-
110-
-u, --targetusername=targetusername username or alias for the target
111-
org; overrides default target org
112-
113-
-v, --targetdevhubusername=targetdevhubusername username or alias for the dev hub
114-
org; overrides default dev hub org
115-
116-
--apiversion=apiversion override the api version used for
117-
api requests made by this command
118-
119-
--json format output as json
120-
121-
--loglevel=(trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL) [default: warn] logging level for
122-
this command invocation
123-
124-
EXAMPLES
125-
$ sfdx hello:org --targetusername [email protected] --targetdevhubusername [email protected]
126-
Hello world! This is org: MyOrg and I will be around until Tue Mar 20 2018!
127-
My hub org id is: 00Dxx000000001234
128-
129-
$ sfdx hello:org --name myname --targetusername [email protected]
130-
Hello myname! This is org: MyOrg and I will be around until Tue Mar 20 2018!
131-
```
132-
133-
<!-- commandsstop -->
69+
# Commands

command-snapshot.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1 @@
1-
[
2-
{
3-
"command": "hello:org",
4-
"plugin": "@salesforce/plugin-template",
5-
"flags": ["apiversion", "force", "json", "loglevel", "name", "targetdevhubusername", "targetusername"]
6-
}
7-
]
1+
[]

messages/deploy.json

Whitespace-only changes.

messages/messages.json

Lines changed: 0 additions & 22 deletions
This file was deleted.

messages/org.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

messages/retrieve.json

Whitespace-only changes.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
2-
"name": "@salesforce/plugin-template",
3-
"description": "A template repository for sfdx plugins",
4-
"version": "1.0.0",
2+
"name": "@salesforce/plugin-source",
3+
"description": "Commands to interact with source formatted metadata",
4+
"version": "0.0.1",
55
"author": "Salesforce",
66
"bugs": "https://github.com/forcedotcom/cli/issues",
77
"dependencies": {
@@ -55,7 +55,7 @@
5555
"/messages",
5656
"/oclif.manifest.json"
5757
],
58-
"homepage": "https://github.com/salesforcecli/plugin-template",
58+
"homepage": "https://github.com/salesforcecli/plugin-source",
5959
"keywords": [
6060
"force",
6161
"salesforce",
@@ -78,7 +78,7 @@
7878
}
7979
}
8080
},
81-
"repository": "salesforcecli/plugin-template",
81+
"repository": "salesforcecli/plugin-source",
8282
"scripts": {
8383
"build": "sf-build",
8484
"clean": "sf-clean",
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/*
2+
* Copyright (c) 2020, salesforce.com, inc.
3+
* All rights reserved.
4+
* Licensed under the BSD 3-Clause license.
5+
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6+
*/
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/*
2+
* Copyright (c) 2020, salesforce.com, inc.
3+
* All rights reserved.
4+
* Licensed under the BSD 3-Clause license.
5+
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6+
*/

src/commands/hello/org.ts

Lines changed: 0 additions & 102 deletions
This file was deleted.

0 commit comments

Comments
 (0)