Skip to content

Commit

Permalink
add build time
Browse files Browse the repository at this point in the history
  • Loading branch information
jgstew committed Jun 7, 2024
1 parent 14f26f9 commit 038e965
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Kaspersky/KasperskyVirusRemovalTool-Win-Run.bes.mustache
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<BES xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="BES.xsd">
<{{TypeTaskOrFixlet}}{{^TypeTaskOrFixlet}}Task{{/TypeTaskOrFixlet}}>
<Title>Run: {{DisplayName}} v{{version}} - Windows</Title>
<Title>Run: {{DisplayName}} v{{version}} {{build_time}} - Windows</Title>
<Description><![CDATA[
This task will run {{DisplayName}} on the system.
]]></Description>
Expand Down
5 changes: 5 additions & 0 deletions Kaspersky/KasperskyVirusRemovalTool-Win.bigfix.recipe.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ Process:

- Processor: com.github.jgstew.SharedProcessors/TemplateDictionaryAppendInput

- Processor: com.github.jgstew.SharedProcessors/TemplateDictionaryAppend
Arguments:
append_key: "build_time"
append_value: "%build_time%"

- Processor: com.github.jgstew.SharedProcessors/ContentFromTemplate
Arguments:
# use UNIX style paths so this works on Windows and non-Windows:
Expand Down
14 changes: 14 additions & 0 deletions Kaspersky/KasperskyVirusRemovalTool-Win.download.recipe.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,17 @@ Process:
Arguments:
input_string: "%version%"
re_pattern: '^\d+\.\d+'

# validate file signature and get signature date as SourceReleaseDate:
- Processor: com.github.jgstew.SharedProcessors/FileExeVerifySignature

# verify SourceReleaseDate is set correctly:
- Processor: com.github.jgstew.SharedProcessors/TextSearcher
Arguments:
input_string: "%SourceReleaseDate%"
re_pattern: '^20\d{2}-[0-1]\d{1}-[0-3]\d{1}$'

- Processor: com.github.jgstew.SharedProcessors/TextSearcher
Arguments:
input_string: "%file_signature_datetime%"
re_pattern: '(?P<build_time>.+)\+'

0 comments on commit 038e965

Please sign in to comment.