From 6ad7baeb2b592f4e3616adbe3865a873879698c3 Mon Sep 17 00:00:00 2001 From: JGStew Date: Tue, 2 Jul 2024 23:07:41 -0400 Subject: [PATCH] firefox macos download recipe example --- Mozilla/Firefox-Mac.download.recipe.yaml | 33 ++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 Mozilla/Firefox-Mac.download.recipe.yaml diff --git a/Mozilla/Firefox-Mac.download.recipe.yaml b/Mozilla/Firefox-Mac.download.recipe.yaml new file mode 100644 index 0000000..09e636d --- /dev/null +++ b/Mozilla/Firefox-Mac.download.recipe.yaml @@ -0,0 +1,33 @@ +# https://download.mozilla.org/?product=firefox-latest-ssl&os=osx&lang=en-US +--- +Description: Downloads the latest version of Firefox +# based upon https://github.com/autopkg/moofit-recipes/blob/master/Adobe/RemoteUpdateManager.download.recipe +Identifier: com.github.jgstew.download.Firefox-Mac +Input: + NAME: "Firefox" + OS: osx + filename: Firefox.dmg +MinimumVersion: "2.3" +Process: + - Processor: com.github.jgstew.SharedProcessors/URLDownloaderPython + Arguments: + # Example URLs: + # - https://download.mozilla.org/?product=firefox-latest-ssl&os=osx&lang=en-US + url: https://download.mozilla.org/?product=firefox-latest-ssl&os=%OS%&lang=en-US + COMPUTE_HASHES: True + + - Processor: EndOfCheckPhase + + - Processor: com.github.jgstew.SharedProcessors/TextSearcher + Arguments: + input_string: "%download_url%" + re_pattern: 'releases/(?P\d+\.\d+\.\d+)/' + + # get SourceReleaseDate from HTTP `Last-Modified` header: + - Processor: com.github.jgstew.SharedProcessors/DateTimeFromString + Arguments: + # parse last_modified header info from URLDownloaderPython + datetime_string: "%last_modified%" + datetime_strptime: "%a, %d %b %Y %H:%M:%S %Z" + datetime_strftime: "%Y-%m-%d" + datetime_parsed_name: SourceReleaseDate