Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a way to change script working directory #256

Open
CompeyDev opened this issue Sep 13, 2024 · 0 comments
Open

Add a way to change script working directory #256

CompeyDev opened this issue Sep 13, 2024 · 0 comments
Labels
enhancement New feature or request pending / needs design Awaiting design and/or implementation discussion and decisions

Comments

@CompeyDev
Copy link
Contributor

An API for changing the directory of a script (namely process.chdir), would be useful to for traversing directories at runtime, instead of being locked into the directory lune run was invoked from.

Potential Design

function process.chdir(dir: string): () end

Drawbacks

This would potentially involve a breaking change, since process.cwd can no longer be a static string computed at builtin initialization time. Instead, it would need to do be a function which dynamically returns the current directory.

@filiptibell filiptibell added enhancement New feature or request pending / needs design Awaiting design and/or implementation discussion and decisions labels Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request pending / needs design Awaiting design and/or implementation discussion and decisions
Projects
None yet
Development

No branches or pull requests

2 participants