MCPcopy Index your code
hub / github.com/upstash/jstack / installPackages

Function installPackages

cli/src/helpers/install-packages.ts:10–33  ·  view source on GitHub ↗
(options: InstallPackagesOptions)

Source from the content-addressed store, hash-verified

8
9// This runs the installer for all the packages that the user has selected
10export const installPackages = (options: InstallPackagesOptions) => {
11 const { installers } = options
12 logger.info("Adding boilerplate...")
13
14 // Handle ORM installers
15 for (const [name, pkgOpts] of Object.entries(installers.orm)) {
16 if (pkgOpts.inUse) {
17 const spinner = ora(`Boilerplating ORM: ${name}...`).start()
18 pkgOpts.installer(options)
19 spinner.succeed(chalk.green(`Successfully setup boilerplate for ORM: ${chalk.green.bold(name)}`))
20 }
21 }
22
23 // Handle provider installers
24 for (const [name, pkgOpts] of Object.entries(installers.provider)) {
25 if (pkgOpts.inUse) {
26 const spinner = ora(`Boilerplating provider: ${name}...`).start()
27 pkgOpts.installer(options)
28 spinner.succeed(chalk.green(`Successfully setup boilerplate for provider: ${chalk.green.bold(name)}`))
29 }
30 }
31
32 logger.info("")
33}

Callers 1

scaffoldProjectFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected