MasonM / avsh

Augmented Vagrant sSH - Faster alternative to "vagrant ssh", with extra features
MIT License
3 stars 0 forks source link

Automatic synced folder switching issue on MacOS Catalina #1

Open danillos opened 5 years ago

danillos commented 5 years ago

This feature stopped to work on Catalina

danillos commented 5 years ago

The sync is not working because of the workaround of this issue where I had to add /System/Volumes/Data for Vagrant work.

To fix the sync issue I had to put src = src.gsub('/System/Volumes/Data', '') on the avsh executable file.


     def match_synced_folder(host_directory, folders)
      vagrantfile_dir = File.dirname(@vagrantfile_path) 
      folders.each do |dest, src|

        src = src.gsub('/System/Volumes/Data', '') # added line

        real_src = File.expand_path(src, vagrantfile_dir)
        next unless host_directory.start_with?(real_src)
        relative_directory = host_directory[real_src.length..-1]
        full_directory = File.join(dest, relative_directory)
        return full_directory
      end
      nil
    end
MasonM commented 5 years ago

I didn't know anyone was still using this! Glad to hear it was helpful to someone.

Unfortunately, I no longer use Vagrant for development, so I'm not maintaining avsh anymore. I'll accept PRs, though.