Sha256: 55d2f9efd1ceee6f43d59b1bf3ec10be728000599f7f3cefce7fcd45a984a4c1

Contents?: true

Size: 716 Bytes

Versions: 14

Compression:

Stored size: 716 Bytes

Contents

module VagrantPlugins
  module SyncedFolderNFSGuest
    module GuestLinux
      module Cap
        class ReadUserIDs
          def self.read_uid(machine)
            command = "id -u"
            result  = ""
            machine.communicate.execute(command) do |type, data|
              result << data if type == :stdout
            end

            result.chomp.split("\n").first
          end

          def self.read_gid(machine)
            command = "id -g"
            result  = ""
            machine.communicate.execute(command) do |type, data|
              result << data if type == :stdout
            end

            result.chomp.split("\n").first
          end
        end
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 2 rubygems

Version Path
vagrant-nfs_guest-1.0.5 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-1.0.3 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-1.0.2 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-1.0.0 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.11 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.10 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.9 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest_vbfix-0.1.10 lib/vagrant-nfs_guest_vbfix/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest_vbfix-0.1.9 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.8 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.7 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.6 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.5 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb
vagrant-nfs_guest-0.1.4 lib/vagrant-nfs_guest/guests/linux/cap/read_user_ids.rb