ZRCola/bin/InstFont.wsf
Simon Rozman 47d3884af3 Update Copyright and build year
Signed-off-by: Simon Rozman <simon@rozman.si>
2022-01-07 11:38:32 +01:00

36 lines
1.0 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!--
SPDX-License-Identifier: GPL-3.0-or-later
Copyright © 2016-2022 Amebis
-->
<package>
<job id="InstFont">
<runtime>
<description>Installs font - Amebis, Copyright © 2016-2022</description>
<unnamed name="&lt;Shortcut.lnk&gt;" required="true" helpstring="Shortcut file to create"/>
<example>
Example:
InstFont.wsf &quot;My Font.ttf&quot;
</example>
</runtime>
<reference object="Scripting.FileSystemObject"/>
<script language="JScript"><![CDATA[
if (WScript.Arguments.Unnamed.Length < 1) {
WScript.Arguments.ShowUsage();
WScript.Quit(1);
}
var
fso = WScript.CreateObject("Scripting.FileSystemObject"),
wap = WScript.CreateObject("Shell.Application"),
filename = fso.GetAbsolutePathName(WScript.Arguments.Unnamed(0)),
folder = wap.Namespace(fso.GetParentFolderName(filename)),
file = folder.ParseName(fso.GetFileName(filename));
file.InvokeVerb("Install");
WScript.Quit(0);
]]></script>
</job>
</package>