Skip to content

Commit

Permalink
Merge pull request #398 from salesforcecli/wr/replaceSfdx
Browse files Browse the repository at this point in the history
docs: replace sfdx with sf
  • Loading branch information
iowillhoit authored Aug 24, 2023
2 parents 3766a4b + 9dd92ac commit cf5e01a
Show file tree
Hide file tree
Showing 11 changed files with 2,092 additions and 557 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/Bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@ _Feel free to attach a screenshot_.

**VS Code Version**:

**SFDX CLI Version**:
**SF CLI Version**:

**OS and version**:
8 changes: 4 additions & 4 deletions DEVELOPING.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@ To run your modified plugin commands locally, use `./bin/dev` or `./bin/dev.cmd`
There should be no differences when running via the Salesforce CLI or using the local scripts. However, it can be useful to link the plugin to do some additional testing or run your commands from anywhere on your machine.

```bash
# Link your plugin to the sfdx cli
sfdx plugins:link .
# Link your plugin to the sf cli
sf plugins:link .
# To verify
sfdx plugins
sf plugins
# To run
sfdx force:package:create --help
sf force package create --help
```

## Useful yarn commands
Expand Down
2,607 changes: 2,070 additions & 537 deletions README.md

Large diffs are not rendered by default.

8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@salesforce/plugin-packaging",
"description": "SFDX plugin that support Salesforce Packaging Platform",
"description": "SF plugin that support Salesforce Packaging Platform",
"version": "1.22.2",
"main": "lib/index.js",
"author": "Salesforce",
Expand Down Expand Up @@ -65,13 +65,15 @@
"force",
"salesforce",
"sfdx",
"sf",
"salesforcedx",
"sfdx-plugin"
"sfdx-plugin",
"sf-plugin"
],
"license": "BSD-3-Clause",
"oclif": {
"commands": "./lib/commands",
"bin": "sfdx",
"bin": "sf",
"additionalVersionFlags": [
"-v"
],
Expand Down
6 changes: 3 additions & 3 deletions test/commands/package/install.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ describe('package:install', () => {
const result = await cmd.run();

expect(uxLogStub.calledOnce).to.be.true;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sfdx package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sf package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
expect(uxLogStub.args[0][0]).to.deep.equal(msg);
expect(result).to.deep.equal(pkgInstallRequest);
expect(installStub.args[0][0]).to.deep.equal(pkgInstallCreateRequest);
Expand All @@ -187,7 +187,7 @@ describe('package:install', () => {
stubSpinner(cmd);
const result = await cmd.run();
expect(uxLogStub.callCount).to.equal(1);
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sfdx package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sf package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
expect(uxLogStub.args[0][0]).to.equal(msg);
expect(uxWarnStub.firstCall.args[0]).to.include(
'The "-u" flag has been deprecated. Use "--target-org | -o" instead.'
Expand Down Expand Up @@ -370,7 +370,7 @@ describe('package:install', () => {

expect(uxLogStub.callCount).to.equal(1);
expect(uxWarnStub.args[0][0]).to.equal(warningMsg);
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sfdx package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sf package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
expect(uxLogStub.args[0][0]).to.equal(msg);
expect(result).to.deep.equal(pkgInstallRequest);
});
Expand Down
2 changes: 1 addition & 1 deletion test/commands/package/installReport.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ describe('package:install:report', () => {
const result = await new Report(['-i', pkgInstallRequest.Id, '--target-org', testOrg.username], config).run();
expect(result).to.deep.equal(pkgInstallRequest);
expect(uxLogStub.calledOnce).to.be.true;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sfdx package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
const msg = `PackageInstallRequest is currently InProgress. You can continue to query the status using${EOL}sf package:install:report -i 0Hf1h0000006sh2CAA -o ${testOrg.username}`;
expect(uxLogStub.args[0][0]).to.equal(msg);
});

Expand Down
2 changes: 1 addition & 1 deletion test/commands/package/packageUninstall.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ describe('package:uninstall', () => {
expect(result.Status).to.equal('InProgress');
expect(logStub.callCount).to.equal(1);
expect(logStub.firstCall.args[0]).to.deep.equal(
`PackageUninstallRequest is currently InProgress.${os.EOL}You can continue to query the status using sfdx package uninstall report -i 06y23000000002MXXX -o ${testOrg.username}`
`PackageUninstallRequest is currently InProgress.${os.EOL}You can continue to query the status using sf package uninstall report -i 06y23000000002MXXX -o ${testOrg.username}`
);
});

Expand Down
2 changes: 1 addition & 1 deletion test/commands/package/packageVersionCreate.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ describe('package:version:create - tests', () => {
});
expect(logStub.callCount).to.equal(1);
expect(logStub.args[0]).to.deep.equal([
`Successfully created the package version [08c3i000000fylgAAA]. Subscriber Package Version Id: 04t3i000002eya2AAA${os.EOL}Package Installation URL: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t3i000002eya2AAA${os.EOL}As an alternative, you can use the "sfdx package:install" command.`,
`Successfully created the package version [08c3i000000fylgAAA]. Subscriber Package Version Id: 04t3i000002eya2AAA${os.EOL}Package Installation URL: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t3i000002eya2AAA${os.EOL}As an alternative, you can use the "sf package:install" command.`,
]);
});

Expand Down
2 changes: 1 addition & 1 deletion test/commands/package/packageVersionCreateReport.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ describe('package:version:create:report - tests', () => {
'(11) SampleDataController: Invalid type: Schema.Property__c\n(12) SampleDataController: Invalid type: Schema.Broker__c'
);
expect(warnStub.secondCall.args[0]).to.deep.equal(
`...${os.EOL}${os.EOL}To see all errors, run: sfdx data:soql:query -t -q "SELECT Message FROM Package2VersionCreateRequestError WHERE ParentRequest.Id='08c3i000000fyoVAAQ'" -o test@hub.org`
`...${os.EOL}${os.EOL}To see all errors, run: sf data:soql:query -t -q "SELECT Message FROM Package2VersionCreateRequestError WHERE ParentRequest.Id='08c3i000000fyoVAAQ'" -o test@hub.org`
);
});
});
Expand Down
2 changes: 1 addition & 1 deletion test/commands/package1/versionCreate.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ describe('package1:version:create', () => {
expect(result.Status).to.equal('QUEUED');
expect(uxLogStub.callCount).to.equal(1);
expect(uxLogStub.firstCall.args[0]).to.equal(
`PackageUploadRequest has been enqueued. You can query the status using${os.EOL}sfdx package1:version:create:get -i 0HD4p000000blUvGXX -o ${testOrg.username}`
`PackageUploadRequest has been enqueued. You can query the status using${os.EOL}sf package1:version:create:get -i 0HD4p000000blUvGXX -o ${testOrg.username}`
);
});

Expand Down
8 changes: 4 additions & 4 deletions test/commands/package1/versionCreateGet.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ describe('package1:version:create:get', () => {
expect(result.Status).to.equal('IN_PROGRESS');
expect(uxStub.callCount).to.equal(1);
// PackageUploadRequest is still InProgress. You can query the status using
// sfdx package1:version:create:get -i 0HD4p000000blUvGXX -o admin_9aabdcd7250f980c5a96bf96fb9a9711@gb.org
// sf package1:version:create:get -i 0HD4p000000blUvGXX -o admin_9aabdcd7250f980c5a96bf96fb9a9711@gb.org
expect(uxStub.args[0][0]).to.match(
/PackageUploadRequest is still InProgress\. You can query the status using\s+sfdx package1:version:create:get -i 0HD4p000000blUvGXX -o admin_.*@.*\.org/
/PackageUploadRequest is still InProgress\. You can query the status using\s+sf package1:version:create:get -i 0HD4p000000blUvGXX -o admin_.*@.*\.org/
);
});

Expand All @@ -99,9 +99,9 @@ describe('package1:version:create:get', () => {
expect(result.Status).to.equal('QUEUED');
expect(uxStub.callCount).to.equal(1);
// "PackageUploadRequest has been enqueued. You can query the status using
// sfdx package1:version:create:get -i 0HD4p000000blUvGXX -o admin_59d2d480323a011b8887b00138d2e9bb@gb.org"
// sf package1:version:create:get -i 0HD4p000000blUvGXX -o admin_59d2d480323a011b8887b00138d2e9bb@gb.org"
expect(uxStub.args[0][0]).to.match(
/PackageUploadRequest has been enqueued\. You can query the status using\s+sfdx package1:version:create:get -i 0HD4p000000blUvGXX -o admin_.*@.*\.org/
/PackageUploadRequest has been enqueued\. You can query the status using\s+sf package1:version:create:get -i 0HD4p000000blUvGXX -o admin_.*@.*\.org/
);
});

Expand Down

0 comments on commit cf5e01a

Please sign in to comment.