Skip to content

--out-dir should be relative to current directory #704

Closed
@mwillsey

Description

@mwillsey

🐛 Bug description

wasm-pack build subdir/ --out-dir pkg dumps the output in $PWD/subdir/pkg/.

🤔 Expected Behavior

Should output to $PWD/pkg, not the subdir. The help says:

-d, --out-dir <out_dir> Sets the output directory with a relative path. [default: pkg]
--out-name <out_name> Sets the output file names. Defaults to package name.

My understanding is that "relative" here means relative to the current working directory.

👟 Steps to reproduce

wasm-pack build subdir/ --out-dir pkg

🌍 Your environment

$ wasm-pack --version
wasm-pack 0.8.1

My use case here is working in a cargo workspace. I like to work in the top-level directory, and keep all of my build artifacts in the top-level target/ directory.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions