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

Allow mapdir aliases with starting / #1660

Merged
merged 5 commits into from
Oct 2, 2020
Merged

Conversation

MarkMcCaskey
Copy link
Contributor

Stripping leading / is valid because we mount mapped dirs at / regardless.

Resolves #1503

This solution is a bit hacky, there may be a more elegant solution. I'll look for one tomorrow morning when I'm more mentally fresh.

  • Add a short description of the the change to the CHANGELOG.md file

Stripping leading `/` is valid because we mount mapped dirs at `/` regardless.
@syrusakbary
Copy link
Member

Can we add tests to the PR?

Mark McCaskey added 2 commits September 30, 2020 16:35
f3af784fb Add mapdir with leading slash test

git-subtree-dir: tests/wasi-wast
git-subtree-split: f3af784fb148ccd5037ae159c39e99b372bad1cf
@syrusakbary
Copy link
Member

bors r+

bors bot added a commit that referenced this pull request Oct 1, 2020
1660: Allow mapdir aliases with starting `/` r=syrusakbary a=MarkMcCaskey

Stripping leading `/` is valid because we mount mapped dirs at `/` regardless.

Resolves #1503 

This solution is a bit hacky, there may be a more elegant solution.  I'll look for one tomorrow morning when I'm more mentally fresh.

- [ ] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Mark McCaskey <mark@wasmer.io>
@syrusakbary
Copy link
Member

bors r-

@bors
Copy link
Contributor

bors bot commented Oct 1, 2020

Canceled.

@MarkMcCaskey
Copy link
Contributor Author

bors r+

bors bot added a commit that referenced this pull request Oct 1, 2020
1660: Allow mapdir aliases with starting `/` r=MarkMcCaskey a=MarkMcCaskey

Stripping leading `/` is valid because we mount mapped dirs at `/` regardless.

Resolves #1503 

This solution is a bit hacky, there may be a more elegant solution.  I'll look for one tomorrow morning when I'm more mentally fresh.

- [ ] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Mark McCaskey <mark@wasmer.io>
@bors
Copy link
Contributor

bors bot commented Oct 1, 2020

Build failed:

@MarkMcCaskey
Copy link
Contributor Author

bors r-

@MarkMcCaskey
Copy link
Contributor Author

bors r+

bors bot added a commit that referenced this pull request Oct 1, 2020
1660: Allow mapdir aliases with starting `/` r=MarkMcCaskey a=MarkMcCaskey

Stripping leading `/` is valid because we mount mapped dirs at `/` regardless.

Resolves #1503 

This solution is a bit hacky, there may be a more elegant solution.  I'll look for one tomorrow morning when I'm more mentally fresh.

- [ ] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Mark McCaskey <mark@wasmer.io>
@bors
Copy link
Contributor

bors bot commented Oct 1, 2020

Build failed:

@MarkMcCaskey
Copy link
Contributor Author

bors r-

@MarkMcCaskey
Copy link
Contributor Author

bors r+

bors bot added a commit that referenced this pull request Oct 1, 2020
1660: Allow mapdir aliases with starting `/` r=MarkMcCaskey a=MarkMcCaskey

Stripping leading `/` is valid because we mount mapped dirs at `/` regardless.

Resolves #1503 

This solution is a bit hacky, there may be a more elegant solution.  I'll look for one tomorrow morning when I'm more mentally fresh.

- [ ] Add a short description of the the change to the CHANGELOG.md file


Co-authored-by: Mark McCaskey <mark@wasmer.io>
@bors
Copy link
Contributor

bors bot commented Oct 1, 2020

Build failed:

These tests are failing because we call `take(N)` on chars of a string
read from a file. It seems that on Windows, the programs get line
endings with `\r\n`, this is a problem for the way our tests assert
correct output.

We'll need to find a general solution to this problem later.
@MarkMcCaskey
Copy link
Contributor Author

bors r+

@bors
Copy link
Contributor

bors bot commented Oct 2, 2020

@bors bors bot merged commit cebf0cd into master Oct 2, 2020
@bors bors bot deleted the fix/aliases-with-leading-slash branch October 2, 2020 00:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The mapdir option unexpectedly maps to the current working directory
2 participants