Skip to content

Commit

Permalink
Merge pull request #172292 from TheMDev/main
Browse files Browse the repository at this point in the history
  • Loading branch information
p-linnane committed May 5, 2024
2 parents 7fc9ea0 + aa26cf5 commit 6383a14
Show file tree
Hide file tree
Showing 14 changed files with 174 additions and 85 deletions.
18 changes: 12 additions & 6 deletions Casks/c/cirrus.rb
Expand Up @@ -10,21 +10,27 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/cirrus(\d+)\.zip}i)
strategy :page_match do |page, regex|
match = page.match(regex)
next if match.blank?
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Cirrus']]"]
next unless item

"#{match[3].split("", 2).join(".")},#{match[1]}.#{match[2]}"
version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :sierra"
depends_on macos: ">= :high_sierra"

app "cirrus#{version.csv.first.major}#{version.csv.first.minor}/Cirrus.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.cirrusmac.sfl*",
"~/Library/Caches/co.eclecticlight.CirrusMac",
"~/Library/HTTPStorages/co.eclecticlight.CirrusMac",
"~/Library/Preferences/co.eclecticlight.CirrusMac.plist",
"~/Library/Saved Application State/co.eclecticlight.CirrusMac.savedState",
]
Expand Down
14 changes: 10 additions & 4 deletions Casks/d/dintch.rb
Expand Up @@ -10,11 +10,16 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
strategy :page_match do |page|
match = page.match(%r{(\d+)/(\d+)/dintch(\d+)\.zip}i)
next if match.blank?
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Dintch']]"]
next unless item

"#{match[3].split("", 2).join(".")},#{match[1]}.#{match[2]}"
version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

Expand All @@ -23,6 +28,7 @@
app "dintch#{version.csv.first.no_dots}/Dintch.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.dintch.sfl*",
"~/Library/Caches/co.eclecticlight.Dintch",
"~/Library/HTTPStorages/co.eclecticlight.Dintch",
"~/Library/Preferences/co.eclecticlight.Dintch.plist",
Expand Down
20 changes: 13 additions & 7 deletions Casks/l/lockrattler.rb
Expand Up @@ -6,24 +6,30 @@
verified: "eclecticlightdotcom.files.wordpress.com/"
name "Lock Rattler"
desc "Checks security systems and reports issues"
homepage "https://eclecticlight.co/"
homepage "https://eclecticlight.co/lockrattler-systhist/"

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/lockrattler(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='LockRattler']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :el_capitan"
depends_on macos: ">= :high_sierra"

app "lockrattler#{version.csv.first.major}#{version.csv.first.minor}/LockRattler.app"

zap trash: [
"~/Library/Caches/co.eclecticlight.LockRattler",
"~/Library/HTTPStorages/co.eclecticlight.LockRattler",
"~/Library/Preferences/co.eclecticlight.LockRattler.plist",
"~/Library/Saved Application State/co.eclecticlight.LockRattler.savedState",
]
Expand Down
20 changes: 13 additions & 7 deletions Casks/m/metamer.rb
Expand Up @@ -10,11 +10,16 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
strategy :page_match do |page|
match = page.match(%r{(\d+)/(\d+)/metamer(\d+)\.zip}i)
next if match.blank?
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Metamer']]"]
next unless item

"#{match[3].split("", 2).join(".")},#{match[1]}.#{match[2]}"
version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

Expand All @@ -23,9 +28,10 @@
app "metamer#{version.csv.first.no_dots}/Metamer.app"

zap trash: [
"~/Library/Caches/co.eclecticlight.Metamer/",
"~/Library/HTTPStorages/co.eclecticlight.Metamer/",
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.metamer.sfl*",
"~/Library/Caches/co.eclecticlight.Metamer",
"~/Library/HTTPStorages/co.eclecticlight.Metamer",
"~/Library/Preferences/co.eclecticlight.Metamer.plist",
"~/Library/Saved Application State/co.eclecticlight.Metamer.savedState/",
"~/Library/Saved Application State/co.eclecticlight.Metamer.savedState",
]
end
18 changes: 12 additions & 6 deletions Casks/m/mints.rb
Expand Up @@ -10,19 +10,25 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/mints(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Mints']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :sierra"
depends_on macos: ">= :high_sierra"

app "mints#{version.csv.first.no_dots}/Mints.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.mints.sfl*",
"~/Library/Caches/co.eclecticlight.Mints",
"~/Library/HTTPStorages/co.eclecticlight.Mints",
"~/Library/Preferences/co.eclecticlight.Mints.plist",
Expand Down
18 changes: 13 additions & 5 deletions Casks/s/signet.rb
Expand Up @@ -10,18 +10,26 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/signet(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Signet']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :high_sierra"

app "#{token}#{version.csv.first.no_dots}/Signet.app"

zap trash: [
"~/Library/Caches/co.eclecticlight.Signet",
"~/Library/HTTPStorages/co.eclecticlight.Signet",
"~/Library/Preferences/co.eclecticlight.Signet.plist",
"~/Library/Saved Application State/co.eclecticlight.Signet.savedState",
]
Expand Down
26 changes: 19 additions & 7 deletions Casks/s/silentknight.rb
Expand Up @@ -6,20 +6,32 @@
livecheck do
skip "Legacy version"
end

depends_on macos: ">= :el_capitan"
end
on_catalina :or_newer do
version "2.07,2023.11"
sha256 "90bc1b10f02f09c2a684a0f04242f2e93b1aadd912e5341bc5a7415cfe8f0c62"

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{(\d+)/(\d+)/silentknight([^1]\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='SilentKnight#{version.major}']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

# Temporarily override the version to account for a one-off mismatch
version = "2.07" if version == "2.7"

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :catalina"
end

url "https://eclecticlightdotcom.files.wordpress.com/#{version.csv.second.major}/#{version.csv.second.minor}/silentknight#{version.csv.first.no_dots}.zip",
Expand All @@ -28,12 +40,12 @@
desc "Automatically checks computer's security"
homepage "https://eclecticlight.co/lockrattler-systhist/"

depends_on macos: ">= :el_capitan"

app "silentknight#{version.csv.first.no_dots}/SilentKnight.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.silentknight.sfl*",
"~/Library/Caches/co.eclecticlight.SilentKnight",
"~/Library/HTTPStorages/co.eclecticlight.SilentKnight",
"~/Library/Preferences/co.eclecticlight.SilentKnight.plist",
"~/Library/Saved Application State/co.eclecticlight.SilentKnight.savedState",
]
Expand Down
10 changes: 4 additions & 6 deletions Casks/s/silnite.rb
Expand Up @@ -9,16 +9,14 @@
homepage "https://eclecticlight.co/lockrattler-systhist/"

livecheck do
url :homepage
regex(%r{href=.*?/(\d+)/(\d+)/silnite[._-]?v?(\d+(?:\.\d+)*\w?)\.zip}i)
url "https://eclecticlight.co/downloads/"
regex(%r{href=.*?/(\d+)/(\d+)/silnite[^"' >]*?\.zip[^>]*?>\s*silnite\s+v?(\d+(?:\.\d+)*)[^a-z)]}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2]},#{match[0]}.#{match[1]}"
end
page.scan(regex).map { |match| "#{match[2]},#{match[0]}.#{match[1]}" }
end
end

depends_on macos: ">= :el_capitan"
depends_on macos: ">= :big_sur"

pkg "silnite#{version.csv.first}/silniteInstaller.pkg"

Expand Down
17 changes: 12 additions & 5 deletions Casks/s/spundle.rb
Expand Up @@ -10,11 +10,16 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{(\d+)/(\d+)/Spundle(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Spundle']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

Expand All @@ -23,7 +28,9 @@
app "spundle#{version.csv.first.no_dots}/Spundle.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.spundle.sfl*",
"~/Library/Caches/co.eclecticlight.Spundle",
"~/Library/HTTPStorages/co.eclecticlight.Spundle",
"~/Library/Preferences/co.eclecticlight.Spundle.plist",
"~/Library/Saved Application State/co.eclecticlight.Spundle.savedState",
]
Expand Down
15 changes: 10 additions & 5 deletions Casks/t/taccy.rb
Expand Up @@ -10,11 +10,16 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/taccy(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Taccy']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

Expand Down
24 changes: 15 additions & 9 deletions Casks/t/thetimemachinemechanic.rb
Expand Up @@ -11,21 +11,27 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/t2m2(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='T2M22']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :sierra"
depends_on macos: ">= :big_sur"

app "t2m2#{version.csv.first.major}#{version.csv.first.minor}/TheTimeMachineMechanic.app"

zap trash: [
"~/Library/Caches/co.eclecticlight.TheTimeMachineMechanic",
"~/Library/Preferences/co.eclecticlight.TheTimeMachineMechanic.plist",
"~/Library/Saved Application State/co.eclecticlight.TheTimeMachineMechanic.savedState",
"~/Library/Caches/co.eclecticlight.TheTimeMachineMechanic2",
"~/Library/HTTPStorages/co.eclecticlight.TheTimeMachineMechanic2",
"~/Library/Preferences/co.eclecticlight.TheTimeMachineMechanic2.plist",
"~/Library/Saved Application State/co.eclecticlight.TheTimeMachineMechanic2.savedState",
]
end
18 changes: 12 additions & 6 deletions Casks/u/ulbow.rb
Expand Up @@ -10,19 +10,25 @@

livecheck do
url "https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist"
regex(%r{/(\d+)/(\d+)/ulbow(\d+)\.zip}i)
strategy :page_match do |page, regex|
page.scan(regex).map do |match|
"#{match[2].split("", 2).join(".")},#{match[0]}.#{match[1]}"
end
regex(%r{/(\d+)/(\d+)/[^/]+?$}i)
strategy :xml do |xml, regex|
item = xml.elements["//dict[key[text()='AppName']/following-sibling::*[1][text()='Ulbow']]"]
next unless item

version = item.elements["key[text()='Version']"]&.next_element&.text&.strip
match = item.elements["key[text()='URL']"]&.next_element&.text&.strip&.match(regex)
next if version.blank? || match.blank?

"#{version},#{match[1]}.#{match[2]}"
end
end

depends_on macos: ">= :sierra"
depends_on macos: ">= :high_sierra"

app "ulbow#{version.csv.first.no_dots}/Ulbow.app"

zap trash: [
"~/Library/Application Support/com.apple.sharedfilelist/com.apple.LSSharedFileList.ApplicationRecentDocuments/co.eclecticlight.ulbow.sfl*",
"~/Library/Caches/co.eclecticlight.Ulbow",
"~/Library/HTTPStorages/co.eclecticlight.Ulbow",
"~/Library/Preferences/co.eclecticlight.Ulbow.plist",
Expand Down

0 comments on commit 6383a14

Please sign in to comment.