From 64a0ccd24f54f26cb76ab97e0a4d52f54780b05d Mon Sep 17 00:00:00 2001 From: Jared Quick Date: Wed, 1 Nov 2017 15:03:06 -0400 Subject: [PATCH] update raspbian detect to also check in os_release Signed-off-by: Jared Quick --- lib/train/platforms/detect/specifications/os.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/train/platforms/detect/specifications/os.rb b/lib/train/platforms/detect/specifications/os.rb index fe0550e4..ca4ccf4e 100644 --- a/lib/train/platforms/detect/specifications/os.rb +++ b/lib/train/platforms/detect/specifications/os.rb @@ -62,7 +62,8 @@ def self.load } plat.name('raspbian').title('Raspbian Linux').in_family('debian') .detect { - if unix_file_exist?('/usr/bin/raspi-config') + if (linux_os_release && linux_os_release['NAME'] =~ /raspbian/i) || \ + unix_file_exist?('/usr/bin/raspi-config') @platform[:release] = unix_file_contents('/etc/debian_version').chomp true end