Polyphase Game Engine
Loading...
Searching...
No Matches
AddonScriptRunner.h
Go to the documentation of this file.
1#pragma once
2
3#if EDITOR
4
5#include <string>
6
19namespace AddonScriptRunner
20{
21 enum class TrustResult
22 {
23 TrustOnce, // Run script this time but don't remember
24 TrustAlways, // Run script and persist trust in installed_addons.json
25 Skip, // Don't run the script; keep the addon installed
26 CancelInstall, // Don't run the script and revert the install
27 };
28
30 bool IsTrustedAddonId(const std::string& id);
31
33 std::string FindBashInterpreter();
34
36 TrustResult ShowTrustModal(const std::string& addonId,
37 const std::string& source,
38 const std::string& scriptRel);
39
43 bool RunOnInstall(const std::string& addonId,
44 const std::string& addonDir,
45 const std::string& scriptRel,
46 std::string& outError);
47}
48
49#endif