vagrant-scp-sync 0.5.25 → 0.5.27

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9cb714f9207494b148c9470d8b01f91cd57c8fff99c797827f050b750b59efd9
4
- data.tar.gz: d68f414a56e4fd8dd096a14d37588cb8247e9e62779a15f4e57d33f9f53e2095
3
+ metadata.gz: b57515d717378b1daf432022a6c9b288503e116b08645bb0ddaa89a14719c295
4
+ data.tar.gz: 5c26d7d94fd7dbafc95efe661617d27c7b4ddbf345b537af7c20a4ef354a2d7c
5
5
  SHA512:
6
- metadata.gz: c1f89779f2a724722bf5c39299c5719854db9b5128e2e204648ddddd206ef20c23e94834989b1e8bf5fa2466a81f0234b1b3b0896bd73d92ccd6648be01e61a2
7
- data.tar.gz: ccfd87df8f36614eaf0825ca3af59ee478df4ecd5ae9a853dad16e1a7b54d9ab47e867054dbedbe27e3769f5dae0326c4bae1c16e16cd939e7d6c1bb93262ec7
6
+ metadata.gz: 90334be946bf82fea5f69fa97f3070e75dec9ee07baa8829d86b995c32bc0138077a956fe065cd69dbac04a3b2f94b3cb565d5f327b0b3709a9ea23082168b2c
7
+ data.tar.gz: 19d2079b97289af6d5366367d58b299fd10a9263603f89e167e34b32652e1cabe58c8c8687c5b5a689f60a5e87697cae56fe662aa90d7f3081fc6a18adf652a8
data/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.5.27](https://github.com/STARTcloud/vagrant-scp-sync/compare/v0.5.26...v0.5.27) (2025-01-15)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * FIle paths with quotes break things, this is an attempt to workaround/fix that - making rubocop happy ([525d3f3](https://github.com/STARTcloud/vagrant-scp-sync/commit/525d3f396c503e79d2a0fc700b6e24de55379321))
9
+
10
+ ## [0.5.26](https://github.com/STARTcloud/vagrant-scp-sync/compare/v0.5.25...v0.5.26) (2025-01-15)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * FIle paths with quotes break things, this is an attempt to workaround/fix that - making rubocop happy ([83bc118](https://github.com/STARTcloud/vagrant-scp-sync/commit/83bc1184d3809da8af81af2e2795f4725615e425))
16
+
3
17
  ## [0.5.25](https://github.com/STARTcloud/vagrant-scp-sync/compare/v0.5.24...v0.5.25) (2025-01-15)
4
18
 
5
19
 
@@ -20,7 +20,7 @@ module VagrantPlugins
20
20
 
21
21
  # This will SCP the files
22
22
  class ScpSyncHelper
23
- def self.scp_single(machine, opts)
23
+ def self.scp_single(machine, opts, scp_path)
24
24
  ssh_info = machine.ssh_info
25
25
  raise Vagrant::Errors::SSHNotReady if ssh_info.nil?
26
26
 
@@ -97,7 +97,7 @@ module VagrantPlugins
97
97
  end
98
98
 
99
99
  # Build and execute the scp command with sync message
100
- synchronize = build_scp_command(ssh_opts, source, target)
100
+ synchronize = build_scp_command(scp_path, ssh_opts, source, target)
101
101
  execute_command(machine, synchronize, true, 'scp_sync_folder', opts)
102
102
  end
103
103
 
@@ -114,9 +114,8 @@ module VagrantPlugins
114
114
  ['ssh', *ssh_opts, "#{ssh_info[:username]}@#{ssh_info[:host]}", "'#{command}'"].join(' ')
115
115
  end
116
116
 
117
- def self.build_scp_command(ssh_opts, source, target)
118
- # Just use 'scp' and let the shell find it, like we do with ssh
119
- ['scp', '-r', *ssh_opts, source, target].join(' ')
117
+ def self.build_scp_command(scp_path, ssh_opts, source, target)
118
+ [scp_path, '-r', *ssh_opts, source, target].join(' ')
120
119
  end
121
120
 
122
121
  def self.execute_command(machine, command, raise_error, message_key, opts)
@@ -2,6 +2,7 @@
2
2
 
3
3
  require 'pathname'
4
4
  require 'vagrant/util/subprocess'
5
+ require 'vagrant/util/which'
5
6
 
6
7
  module VagrantPlugins
7
8
  module ScpSync
@@ -21,14 +22,16 @@ module VagrantPlugins
21
22
  if @source.nil? && @target.nil?
22
23
  folders = machine.config.vm.synced_folders
23
24
  ssh_info = machine.ssh_info
25
+ scp_path = Vagrant::Util::Which.which('scp')
24
26
  machine.ui.warn(I18n.t('vagrant.scp_ssh_password')) if ssh_info[:private_key_path].empty? && ssh_info[:password]
25
27
  folders.each_value do |folder_opts|
26
28
  next unless folder_opts[:type] == :scp
27
29
 
28
- VagrantPlugins::ScpSync::ScpSyncHelper.scp_single(machine, folder_opts)
30
+ VagrantPlugins::ScpSync::ScpSyncHelper.scp_single(machine, folder_opts, scp_path)
29
31
  end
30
32
  else
31
33
  ssh_info = machine.ssh_info
34
+ scp_path = Vagrant::Util::Which.which('scp')
32
35
  direction = net_ssh_command(@source)
33
36
  source = format_file_path(machine, @source)
34
37
  target = format_file_path(machine, @target)
@@ -46,7 +49,7 @@ module VagrantPlugins
46
49
  hostpath: source
47
50
  }
48
51
 
49
- VagrantPlugins::ScpSync::ScpSyncHelper.scp_single(machine, folder_opts)
52
+ VagrantPlugins::ScpSync::ScpSyncHelper.scp_single(machine, folder_opts, scp_path)
50
53
  end
51
54
  end
52
55
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Vagrant
4
4
  module ScpSync
5
- VERSION = '0.5.25'
5
+ VERSION = '0.5.27'
6
6
  NAME = 'vagrant-scp-sync'
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-scp-sync
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.25
4
+ version: 0.5.27
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Gilbert