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

/tmp/fnm_multishell_* directories pile up over time #419

Closed
sersorrel opened this issue Mar 31, 2021 · 4 comments · Fixed by #422
Closed

/tmp/fnm_multishell_* directories pile up over time #419

sersorrel opened this issue Mar 31, 2021 · 4 comments · Fixed by #422

Comments

@sersorrel
Copy link

It seems like a new /tmp/fnm_multishell_* directory is created on every shell startup. These seem to never be deleted apart from when /tmp is cleared on reboot. Is there a way that the relevant directory/directories could be deleted on shell shutdown?

(actually, it looks like several directories are created on shell startup, and even more every time I run a command – I guess this is probably some brokenness with my prompt)

I'm using Fish 3.2.1 and fnm 1.23.2, on Ubuntu 18.04.

@sersorrel
Copy link
Author

fwiw, my prompt issue can be avoided by testing status is-interactive before sourcing fnm, but I guess this would break any feature of the prompt that invokes node

@Schniz
Copy link
Owner

Schniz commented Mar 31, 2021

This is not a directory but a symlink. It is almost zero size. Does it really matter? Why is this a concern?

Would it be better if it was /tmp/fnm_multishell/1,2,3,4? So it wasn't shadow but contained inside a directory?

@Schniz
Copy link
Owner

Schniz commented Mar 31, 2021

Would it be better if it was /tmp/fnm_multishell/1,2,3,4? So it wasn't shadow but contained inside a directory?

By the way, up until I commented that I haven't thought about nesting everything under a single directory inside the temp directory. Let me know if that's something you think is worth doing. Would appreciate your input!

@sersorrel
Copy link
Author

I brought it up because it ends up making /tmp basically unusable for anything else – if you open it in a file manager, it's just full of fnm directories:

image

so putting them all in a subdirectory would solve that :)

The other potential issue is that if you put enough files into a directory, accessing that directory can become slow, but I think that's only usually an issue with 100k+ files, so it's probably not a problem? I have about 1 thousand fnm_multishell links in /tmp currently, and fnm has been installed for about 3 days; at that rate it would take over six months even to hit the FAT32 limit of 65534 files in a directory, and modern filesystems can deal with more than that.

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 a pull request may close this issue.

2 participants