question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Naming convention for site collection commands

See original GitHub issue

What do you think would be the logical naming convention for working with site collections in the CLI?

Today, we have classic and modern sites. While they’re both site collections, you work with them differently (different API, parameters and shape). In PnP PowerShell there are two sets of cmdlets: PnPTenantSite for classic sites and PnPSite for modern sites. What would be the logical naming convention to use in the CLI?

  1. spo site <action> for modern and spo site classic <action> for classic sites (since modern sites are likely the way forward it would be better to not include modern in the command name, and instead explicitly denote classic sites)
  2. spo modernsite <action> and spo classicsite <action>
  3. spo site modern <action> and spo site classic <action> to explicitly denote type of site you want to be working with
  4. spo site <action> --type Modern|Classic for both classic and modern. Distinction between classic in modern is done inside each command. This would introduce higher complexity of all commands because they would have to handle two types of sites, including validating required options which are different depending on the type of site you’re working with. Preferably we shouldn’t choose this approach but maybe you have good arguments for doing it.

Any other naming conventions? Which one has your preference and why? @VelinGeorgiev @estruyf @andrewconnell @wictorwilen

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
andrewconnellcommented, Dec 11, 2017

Correct… I think to go in line with what most CLIs do I’d expect to see something more like option 4:

spo site list --type classic
spo site list --type modern
# the following is the same as the modern option above
spo site list
2reactions
bensteginkcommented, Dec 9, 2017

I vote for #1 as well

Read more comments on GitHub >

github_iconTop Results From Across the Web

Naming Conventions for Collections / Views - ArangoDB
View names must always start with a letter. User-defined collection names must always start with a letter. System collection names must start with...
Read more >
Naming conventions | Cloud APIs
Naming conventions · Product names · Service names · Package names · Collection IDs · Interface names · Method names · Message names...
Read more >
Naming Conventions - PowerShell Practice and Style - GitBook
Naming Conventions · Use the full name of each command. · Use full parameter names. · Use full, explicit paths when possible. ·...
Read more >
SharePoint Naming Conventions Best Practices You Should ...
This SharePoint tutorial explains about sharepoint naming conventions, how to give proper names for documents or how to follow proper naming ...
Read more >
Naming conventions - IBM
Names with single-byte characters. The following naming rules apply when saving objects in the database. Names for queries, forms, procedures, tables, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found