Home / Function/ getExecInputForPlatform() — astro Function Reference

getExecInputForPlatform() — astro Function Reference

Architecture documentation for the getExecInputForPlatform() function in open-docs.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  e20cc44b_fc8a_531c_5e96_abf1e7bf9c13["getExecInputForPlatform()"]
  e747d472_6996_c37d_df20_4820655907c4["open-docs.ts"]
  e20cc44b_fc8a_531c_5e96_abf1e7bf9c13 -->|defined in| e747d472_6996_c37d_df20_4820655907c4
  32b90bcd_a2cd_dd61_acf3_f427c9ba9147["openDocsCommand.run()"]
  32b90bcd_a2cd_dd61_acf3_f427c9ba9147 -->|calls| e20cc44b_fc8a_531c_5e96_abf1e7bf9c13
  style e20cc44b_fc8a_531c_5e96_abf1e7bf9c13 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/astro/src/cli/docs/core/open-docs.ts lines 14–28

function getExecInputForPlatform(platform: string): [command: string, args?: Array<string>] | null {
	switch (platform) {
		case 'android':
		case 'linux':
			return ['xdg-open'];
		case 'darwin':
			return ['open'];
		case 'win32':
			return ['cmd', ['/c', 'start']];
		case 'gitpod':
			return ['/ide/bin/remote-cli/gitpod-code', ['--openExternal']];
		default:
			return null;
	}
}

Domain

Subdomains

Frequently Asked Questions

What does getExecInputForPlatform() do?
getExecInputForPlatform() is a function in the astro codebase, defined in packages/astro/src/cli/docs/core/open-docs.ts.
Where is getExecInputForPlatform() defined?
getExecInputForPlatform() is defined in packages/astro/src/cli/docs/core/open-docs.ts at line 14.
What calls getExecInputForPlatform()?
getExecInputForPlatform() is called by 1 function(s): openDocsCommand.run.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free