Skip to content

Commit

Permalink
chore(cli): update help copy for CLI commands
Browse files Browse the repository at this point in the history
  • Loading branch information
binoy14 committed Feb 6, 2024
1 parent b7101d5 commit f2d9e59
Show file tree
Hide file tree
Showing 27 changed files with 29 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Examples
const codemodCommand: CliCommandDefinition = {
name: 'codemod',
signature: '[CODEMOD_NAME]',
description: 'Runs a code modification script',
description: 'Executes a code modification script to update Sanity Studio codebase',
helpText,
action: codemodAction,
}
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/debug/debugCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Examples
const debugCommand: CliCommandDefinition = {
name: 'debug',
signature: '[--secrets]',
description: 'Gathers information on Sanity environment',
description: 'Provides detailed diagnostic information for troubleshooting a Sanity Studio',
helpText: help,
action: printDebugInfo,
}
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/docs/docsCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const docsCommand: CliCommandDefinition = {
name: 'docs',
helpText: '',
signature: 'docs',
description: 'Opens the Sanity documentation',
description: 'Opens the official Sanity Studio documentation in your default web browser',
async action(args, context) {
const {output} = context
const {print} = output
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/help/helpCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ the command list.
const command: CliCommandDefinition = {
name: 'help',
signature: '[COMMAND]',
description: 'Displays help information about Sanity',
description: 'Displays help information about Sanity CLI commands',
action: showHelp,
helpText: help,
}
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/init/initCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export interface InitFlags {
export const initCommand: CliCommandDefinition<InitFlags> = {
name: 'init',
signature: '',
description: 'Initialize a new Sanity Studio project',
description: 'Initializes a new Sanity Studio and/or a project',
helpText,
action: async (args, context) => {
const {output, chalk, prompt} = context
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const installCommand: CliCommandDefinition = {
name: 'install',
signature: '',
helpText: '',
description: 'Installs dependencies of the current project',
description: 'Installs dependencies for a Sanity Studio project',
action: async (args, context) => {
const {workDir, prompt, sanityMajorVersion} = context
const packages = args.argsWithoutOptions
Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/login/loginCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const loginCommand: CliCommandDefinition = {
name: 'login',
signature: '[--sso <slug>] [--provider <providerId>] [--no-open]',
helpText,
description: 'Authenticates against the Sanity.io API',
description: 'Authenticates the CLI for necessary access to your Sanity projects',
action: login,
}

Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/logout/logoutCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const logoutCommand: CliCommandDefinition = {
name: 'logout',
helpText,
signature: 'logout',
description: 'Logs out of the Sanity.io session',
description: 'Logs out the CLI from the current user session',
async action(args, {output, apiClient}) {
const cfg = getUserConfig()

Expand Down
2 changes: 1 addition & 1 deletion packages/@sanity/cli/src/commands/manage/manageCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const manageCommand: CliCommandDefinition = {
name: 'manage',
signature: 'manage',
helpText: '',
description: 'Opens the Sanity project management UI',
description: 'Opens the Sanity project management interface in your web browser',
async action(args, context) {
const {output, cliConfig} = context
const {print} = output
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const projectGroup: CliCommandGroupDefinition = {
name: 'projects',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with projects connected to your logged in user',
description: 'Lists all Sanity projects associated with your logged-in user account',
}

export default projectGroup
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const telemetryGroup: CliCommandGroupDefinition = {
name: 'telemetry',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with telemetry settings for your logged in user',
description: 'Manages telemetry settings, opting in or out of data collection',
}

export default telemetryGroup
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ checks the npm registry for the latest available versions.`
export default {
name: 'versions',
signature: '',
description: 'Shows the installed versions of Sanity CLI and core components',
description: 'Displays the installed versions of Sanity Studio and core components',
helpText: help,
action: printVersionResult,
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Examples
const buildCommand: CliCommandDefinition = {
name: 'build',
signature: '[OUTPUT_DIR]',
description: 'Builds the current Sanity configuration to a static bundle',
description: 'Builds the current Sanity Studio configuration into a static bundle for deployment',
action: async (
args: CliCommandArguments<BuildSanityStudioCommandFlags>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const corsGroup: CliCommandGroupDefinition = {
name: 'cors',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with CORS-entries for your project',
description: 'Configures Cross-Origin Resource Sharing (CORS) settings for Sanity projects',
}

export default corsGroup
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@ export default {
name: 'dataset',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with datasets in your project',
description:
'Manages datasets within your Sanity projects, such as creating or deleting datasets',
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Examples
const deployCommand: CliCommandDefinition = {
name: 'deploy',
signature: '[SOURCE_DIR] [--no-build] [--source-maps] [--no-minify]',
description: 'Deploys a statically built Sanity studio',
description: 'Deploys a statically built studio to the Sanity hosting environment',
action: async (
args: CliCommandArguments<DeployStudioActionFlags>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Examples
const undeployCommand: CliCommandDefinition = {
name: 'undeploy',
signature: '',
description: 'Removes the deployed studio from <hostname>.sanity.studio',
description: 'Removes the deployed Sanity Studio from the studio hosting',
action: async (
args: CliCommandArguments<Record<string, unknown>>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Examples
const devCommand: CliCommandDefinition = {
name: 'dev',
signature: '[--port <port>] [--host <host>]',
description: 'Starts a development server for the Sanity Studio',
description: 'Starts the local development server for Sanity Studio with live reloading',
action: async (
args: CliCommandArguments<StartDevServerCommandFlags>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const documentsGroup: CliCommandGroupDefinition = {
name: 'documents',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with documents in your project',
description: 'Manages and interacts with documents in your Sanity Content Lake datasets',
}

export default documentsGroup
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Examples
export const execCommand: CliCommandDefinition = {
name: 'exec',
signature: 'SCRIPT',
description: 'Runs a script in Sanity context',
description: 'Executes a given script within the context of Sanity Studio',
helpText,
action: async (args, context) => {
const mod = await import('../../actions/exec/execScript')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const graphqlGroup: CliCommandGroupDefinition = {
name: 'graphql',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with GraphQL APIs',
description: "Create and deploy changes to your project's GraphQL API(s)",
}

export default graphqlGroup
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const hookGroup: CliCommandGroupDefinition = {
name: 'hook',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interact with hooks in your project',
description: 'Set up and manages webhooks within your Sanity project',
}

export default hookGroup
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ export default {
name: 'migration',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Scaffold and run migrations against your project dataset',
description: 'Manage content migrations for Sanity Content Lake datasets',
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Examples
const previewCommand: CliCommandDefinition = {
name: 'preview',
signature: '[BUILD_OUTPUT_DIR] [--port <port>] [--host <host>]',
description: 'Starts a local web server for previewing production build',
description: 'Starts a local web server to preview a production build of Sanity Studio',
action: async (
args: CliCommandArguments<StartPreviewServerCommandFlags>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ export default {
name: 'schema',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Interacts with schema(s) in your Sanity Studio project',
description: 'Interacts with Sanity Studio schema configurations',
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ Examples
const startCommand: CliCommandDefinition = {
name: 'start',
signature: '[BUILD_OUTPUT_DIR] [--port <port>] [--host <host>]',
description: 'Alias of `sanity preview`',
description:
'Alias for `sanity preview` to run a local preview of a production built Sanity Studio',
action: async (
args: CliCommandArguments<StartPreviewServerCommandFlags>,
context: CliCommandContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export const usersGroup: CliCommandGroupDefinition = {
name: 'users',
signature: '[COMMAND]',
isGroupRoot: true,
description: 'Manage users of your project',
description: 'Manages users of your Sanity project',
}

export default usersGroup

0 comments on commit f2d9e59

Please sign in to comment.