require 'package' class Nushell < Package description 'A new type of shell' homepage 'https://www.nushell.sh/' version '0.112.2' license 'MIT' compatibility 'aarch64 armv7l x86_64' min_glibc '2.28' source_url({ aarch64: "https://github.com/nushell/nushell/releases/download/#{version}/nu-#{version}-armv7-unknown-linux-gnueabihf.tar.gz", armv7l: "https://github.com/nushell/nushell/releases/download/#{version}/nu-#{version}-armv7-unknown-linux-gnueabihf.tar.gz", x86_64: "https://github.com/nushell/nushell/releases/download/#{version}/nu-#{version}-x86_64-unknown-linux-gnu.tar.gz" }) source_sha256({ aarch64: '2978412a5a8d70d1a92be3f98b3cb967f5db232de9731b2711f42b4bd8bc4293', armv7l: '2978412a5a8d70d1a92be3f98b3cb967f5db232de9731b2711f42b4bd8bc4293', x86_64: '4038c171dd2618f2413a2aa615b8dab7e9d04852be8200f1755df3e422328395' }) no_compile_needed no_shrink def self.install Dir['nu*'].each do |bin| FileUtils.install bin, "#{CREW_DEST_PREFIX}/bin/#{bin}", mode: 0o755 end end def self.postinstall ExitMessage.add "\nType 'nu' to get started.\n" end def self.postremove Package.agree_to_remove("#{CREW_PREFIX}/.config/nushell") end end