Skip to content

If unable to determine dependency manager, build hook command causes build to fail #238

Open
@gilzow

Description

@gilzow

For javascript-based projects, we ONLY determine the use of npm; we do so via the presence of a package-lock.json file. . If a user has a NextJS project, but is using a different package manager (e.g. pnpm), the command determines the stack, and the language correctly, but fails to include the dependency manager:

✓ Detected stack: Next.js
✓ Detected runtime: JavaScript/Node.js
Tell us your project's application name: [www]

If the user continues, the resulting build hook fails to include any install commands of the dependencies:

build: |
        set -eux
        npx next build

This causes the build to fail. If a new user to platform.sh/upsun is trying to follow the guides/documents, they have no idea that they need to manually change the build hook to include a dependency manager install step, and possibly the installation of the package manager in use.

If we are unable to determine the dependency manager in use, we should at least warn the user that additional steps may be needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions