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

Lock is created outside of /tmp if name looks like an absolute path #2

Closed
lpil opened this issue Apr 16, 2022 · 3 comments
Closed

Lock is created outside of /tmp if name looks like an absolute path #2

lpil opened this issue Apr 16, 2022 · 3 comments

Comments

@lpil
Copy link

lpil commented Apr 16, 2022

For example, if a lock is named /one/two the file will be created at /one/two.lock.

I actually think this is quite a useful behaviour, but I think it may need to be documented.

@oblique
Copy link
Owner

oblique commented Apr 16, 2022

Nice! We can convert this bug to a feature :)

@oblique
Copy link
Owner

oblique commented Apr 20, 2022

To keep NamedLocked::create cross-platform and consisted, I decided to return an error on / and \ characters. But I will introduce NamedLock::with_path if someone wants to use a lock file outside /tmp.

If you have any comments on #4, let me know.

@oblique
Copy link
Owner

oblique commented Apr 21, 2022

Version 0.2.0 is published

@oblique oblique closed this as completed Apr 21, 2022
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

No branches or pull requests

2 participants