mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-09 15:37:56 -05:00
Add self.remove package section
This commit is contained in:
6
crew
6
crew
@@ -499,7 +499,7 @@ def download
|
||||
Dir.chdir CREW_BREW_DIR do
|
||||
unless ENV["CREW_CACHE_OPT"].to_s == ''
|
||||
unless File.directory?(CREW_CACHE_DIR)
|
||||
FileUtils.mkdir_p(CREW_CACHE_DIR)
|
||||
FileUtils.mkdir_p(CREW_CACHE_DIR)
|
||||
end
|
||||
if File.file?("#{CREW_CACHE_DIR}#{filename}")
|
||||
if Digest::SHA256.hexdigest( File.read("#{CREW_CACHE_DIR}#{filename}") ) == sha256sum then
|
||||
@@ -973,8 +973,10 @@ def remove (pkgName)
|
||||
file.write JSON.pretty_generate(out)
|
||||
end
|
||||
|
||||
puts "#{pkgName.capitalize} removed!".lightgreen
|
||||
set_package pkgName, true
|
||||
@pkg.remove
|
||||
|
||||
puts "#{pkgName.capitalize} removed!".lightgreen
|
||||
end
|
||||
|
||||
def build_command (args)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Defines common constants used in different parts of crew
|
||||
|
||||
CREW_VERSION = '1.5.2'
|
||||
CREW_VERSION = '1.5.3'
|
||||
|
||||
ARCH_ACTUAL = `uname -m`.strip
|
||||
# This helps with virtualized builds on aarch64 machines
|
||||
|
||||
@@ -105,6 +105,11 @@ class Package
|
||||
|
||||
end
|
||||
|
||||
# Function to perform after package removal.
|
||||
def self.remove
|
||||
|
||||
end
|
||||
|
||||
def self.system(*args)
|
||||
# add "-j#" argument to "make" at compile-time, if necessary
|
||||
|
||||
|
||||
Reference in New Issue
Block a user