Skip to content

membrane.cmd uses current directory instead of script directory #2255

@coderabbitai

Description

@coderabbitai

Issue Description

The Windows batch script distribution/examples/xml/namespaces/membrane.cmd uses %CD% to set the initial directory, which resolves to the current working directory where the script is executed from, not the directory where the script is located.

This differs from the POSIX script (membrane.sh) which correctly uses the script's own directory. If a user runs this script from a different directory (e.g., C:\other\path> C:\membrane\examples\xml\namespaces\membrane.cmd), the upward traversal will start from C:\other\path instead of the script's location, causing it to fail to locate the Membrane root.

Affected File

  • distribution/examples/xml/namespaces/membrane.cmd (line 3)

Expected Behavior

The script should use %~dp0 to get the script's own directory, similar to how membrane.sh uses the script's directory.

Related PR

Reported by: @predic8

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No fields configured for Task.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions