Files
chromebrew/packages/crew_sudo.rb
SupeChicken666 4cc5ef9d6b New package: crew-sudo (#8832)
* New package: crew_sudo

* Add `no_compile_needed` flag

* Fix git tag

* Fix mkdir usage

* Update path

* Update crew_sudo.rb

* Fix grammar

* Switch to main branch for testing

* Print post-instal message with `ExitMessage`

* Move install logic to `crew-sudo` repo

* Bump version and make rubocop happy

* Move repo to chromebrew org
2024-01-24 10:50:40 -05:00

33 lines
835 B
Ruby

require 'package'
class Crew_sudo < Package
description 'Workaround for using sudo on ChromeOS crosh shell (ChromeOS v117+)'
homepage 'https://github.com/chromebrew/crew-sudo'
version '1.1'
license 'GPL-3'
compatibility 'all'
source_url 'https://github.com/chromebrew/crew-sudo.git'
git_hashtag "v#{@version}"
no_compile_needed
def self.install
system({ 'CREW_DEST_PREFIX' => CREW_DEST_PREFIX }, './install.sh')
end
def self.postinstall
ExitMessage.add <<~EOT
In order to make sudo work properly, the crew-sudo daemon needs to
start in the VT-2 shell every boot by:
- Press Ctrl + Alt + -> to enter VT-2 shell
- Log in as 'chronos' user
- The daemon should start automatically now
- Press Ctrl + Alt + <- to switch back to ChromeOS UI
EOT
end
end