Files
chromebrew/packages/crystal.rb
chromebrew-actions[bot] 4282825223 'updater-crystal-1.19.1' (#14240)
* Add unbuilt crystal to updater-crystal-1.19.1

* updater-crystal-1.19.1: Package File Update Run on linux/amd64 container.

---------

Co-authored-by: github-merge-queue <github-merge-queue@users.noreply.github.com>
Co-authored-by: chromebrew-actions[bot] <chromebrew-actions[bot]@users.noreply.github.com>
2026-01-21 02:41:28 +00:00

22 lines
795 B
Ruby

require 'package'
class Crystal < Package
description 'A language for humans and computers'
homepage 'https://crystal-lang.org/'
version '1.19.1'
license 'Apache-2.0'
compatibility 'x86_64'
source_url "https://github.com/crystal-lang/crystal/releases/download/#{version}/crystal-#{version}-1-linux-x86_64-bundled.tar.gz"
source_sha256 'b36c64a621d95308e5b010371c97783567441f33bd9a1a0c6f04de32855225ef'
no_compile_needed
print_source_bashrc
def self.install
FileUtils.mkdir_p %W[#{CREW_DEST_LIB_PREFIX} #{CREW_DEST_PREFIX}/etc/bash.d]
FileUtils.mv %w[bin share], CREW_DEST_PREFIX
FileUtils.mv Dir['lib/*'], CREW_DEST_LIB_PREFIX
FileUtils.ln_s "#{CREW_PREFIX}/share/bash-completion/completions/crystal", "#{CREW_DEST_PREFIX}/etc/bash.d/10-crystal"
end
end