Skip to content

[Bug]: rootDir assumes --options is used and config file is in project root #525

Description

@pjeby

Plugin

@knodes/typedoc-pluginutils

Typedoc plugin(s) version(s)

@knodes/typedoc-pluginutils@0.23.4, @knodes/typedoc-plugin-pages@0.23.4

Typedoc version

0.25.4

Describe the problem

The rootDir calculation in ABasePlugin makes two invalid assumptions that result in errors in some projects.

First, if --options has been specified, but the options file is in a subdirectory of the project, the selected root directory is incorrect.

Second, if --options has not been specified as a command-line argument, it tries to statSync(undefined) (in rootDir from utils/misc.js).

What did you expected ?

The rootDir to be calculated independently of --options and without throwing an error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions