mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
feat: create a deprecation disclaimer file in devPlugins
This commit is contained in:
parent
94a8d0c7f9
commit
8565cbc5ea
1 changed files with 13 additions and 0 deletions
|
|
@ -45,6 +45,15 @@ internal partial class PluginManager : IDisposable, IServiceType
|
|||
/// </summary>
|
||||
public const int PluginWaitBeforeFreeDefault = 500;
|
||||
|
||||
private const string DevPluginsDisclaimerFilename = "DONT_USE_THIS_FOLDER.txt";
|
||||
|
||||
private const string DevPluginsDisclaimerText = @"Hey!
|
||||
The devPlugins folder is deprecated and will be removed soon. Please don't use it anymore for plugin development.
|
||||
Instead, open the Dalamud settings and add the path to your plugins build output folder as a dev plugin location.
|
||||
Remove your devPlugin from this folder.
|
||||
|
||||
Thanks and have fun!";
|
||||
|
||||
private static readonly ModuleLog Log = new("PLUGINM");
|
||||
|
||||
private readonly object pluginListLock = new();
|
||||
|
|
@ -72,6 +81,10 @@ internal partial class PluginManager : IDisposable, IServiceType
|
|||
if (!this.devPluginDirectory.Exists)
|
||||
this.devPluginDirectory.Create();
|
||||
|
||||
var disclaimerFileName = Path.Combine(this.devPluginDirectory.FullName, DevPluginsDisclaimerFilename);
|
||||
if (!File.Exists(disclaimerFileName))
|
||||
File.WriteAllText(disclaimerFileName, DevPluginsDisclaimerText);
|
||||
|
||||
this.SafeMode = EnvironmentConfiguration.DalamudNoPlugins || this.configuration.PluginSafeMode || this.startInfo.NoLoadPlugins;
|
||||
|
||||
try
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue