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

recursive folder synchronization is quite slow when there are lots of files. #152

Closed
zspencer opened this issue Feb 13, 2016 · 3 comments
Closed

Comments

@zspencer
Copy link

Apologies for the poorly worded title; I'm not sure exactly what I'm asking for here, so feel free to tell me to come back when I have a clearer issue.

I am using homeshick to link my .atom/packages directory between machines. It's quite nice! However... atom packages are npm packages with thousands of recursive node_modules folders!

When I have about a dozen packages installed, this results in ~4+ minute homeshick link calls; as there are just so many files and folders to verify are linked correctly.

I would absolutely love it if I could somehow tell homeshick to just link the entire directory instead of trying to link all the files.

I gandered at the source; and assumed that this is what it's supposed to be doing? But my BASH reading comprehension is about at a 4 year old level; so anything beyond "Cow go moo/duck go quack" is a bit beyond me and I could be mistaken in how symlinking of directories is intended to work.

@nielssorensen
Copy link

I'm pretty sure you should leave your npm (your node package manager) to manage your packages and homeshick to manage your dotfiles (generally configuration files). One tool to do one job another to do another. There is a reason for such delineation but someone else can correct me if I'm wrong.

@andsens
Copy link
Owner

andsens commented Feb 14, 2016

@nielssorensen

I'm pretty sure you should leave your npm (your node package manager) to manage your packages and homeshick to manage your dotfiles

There's some truth to that. Tracking files which can be downloaded from somewhere else fully automatically might not make sense.

@zspencer

I would absolutely love it if I could somehow tell homeshick to just link the entire directory instead of trying to link all the files.

You can totally do that :-)

But my BASH reading comprehension is about at a 4 year old level; so anything beyond "Cow go moo/duck go quack" is a bit beyond me

Haha, man I got to remember this analogy!

Anywho, I think the question is answered. Feel free to reopen if you disagree.

@andsens andsens closed this as completed Feb 14, 2016
@zspencer
Copy link
Author

Re: Shallow Linking - This is exactly what I want! Thanks a ton!

Re: Using a package manager - I totally agree! And for system-level dependencies I use a script ensure-consistent-packages that installs stuff with brew/npm/gem/etc.

For editors like sublime/vim/emacs; the "package manager" is to clone X repo and put it in Y directory; which is perfect for homeshick. The issue only really arises with atom because atom packages are npm packages; but installed in a particular location. Turns out there is a command line tool apm which I could call from my ensure-consistent-packages script; but that would require me to manually update the script when I add a package via Atom's built in package manager.

All told, shallow linking does exactly what I want, and cuts run time of homeshick link down to 10~20s again from the ~4m it was taking when I linked each file in .atom/packages directly.

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

3 participants