Sha256: 6edf4324946c047e8e1210763b9cc899059067bfed6eeeb856c091706fadaa84
Contents?: true
Size: 426 Bytes
Versions: 7
Compression:
Stored size: 426 Bytes
Contents
require 'net/http' class Nib::CheckForUpdate def self.execute(_, _) return if installed == latest puts <<-MESSAGE An update is available for nib: #{latest} Use 'nib update' to install the latest version MESSAGE end def self.installed Nib::VERSION end def self.latest url = 'https://raw.githubusercontent.com/technekes/nib/master/VERSION' Net::HTTP.get(URI.parse(url)) end end
Version data entries
7 entries across 7 versions & 1 rubygems