Skip to content

Commit 07caed9

Browse files
authored
Merge pull request #9 from swiftly-solution/beta
2 parents 0048578 + a11babf commit 07caed9

File tree

4 files changed

+11
-2
lines changed

4 files changed

+11
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public partial class PluginClassName : BasePlugin {
8181

8282
public override void Load(bool hotReload)
8383
{
84-
Console.WriteLine("Hello World!!");
84+
Console.WriteLine("Hello World!");
8585
// Check examples folder for more information. Don't forget to delete the folder after reading.
8686
}
8787

gitversion.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,13 @@ branches:
1414
label: beta
1515
is-release-branch: false
1616
is-main-branch: false
17+
source-branches: [ master ]
1718
ignore:
1819
sha: []
1920
merge-message-formats: {}
2021
commit-message-incrementing: Enabled
2122
major-version-bump-message: '\+semver:\s?(breaking|major)'
2223
minor-version-bump-message: '\+semver:\s?(feature|minor)'
2324
patch-version-bump-message: '\+semver:\s?(fix|patch)'
24-
tag-prefix: 'v'
25+
tag-prefix: v
2526
commit-date-format: yyyy-MM-dd

managed/src/SwiftlyS2.Core/Modules/Plugins/SwiftlyCore.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,11 @@ internal class SwiftlyCore : ISwiftlyCore, IDisposable {
5959
public Localizer Localizer { get; init; }
6060
public PermissionManager PermissionManager { get; init; }
6161
public RegistratorService RegistratorService { get; init; }
62+
public string ContextBasePath { get; init; }
6263
public SwiftlyCore(string contextId, string contextBaseDirectory, PluginManifest? pluginManifest, Type contextType, IServiceProvider coreProvider) {
6364

6465
CoreContext id = new(contextId, contextBaseDirectory, pluginManifest);
66+
ContextBasePath = contextBaseDirectory;
6567

6668
ServiceCollection services = new();
6769

@@ -178,4 +180,5 @@ public void Dispose() {
178180
ILocalizer ISwiftlyCore.Localizer => Localizer;
179181
IPermissionManager ISwiftlyCore.Permission => PermissionManager;
180182
IRegistratorService ISwiftlyCore.Registrator => RegistratorService;
183+
string ISwiftlyCore.PluginPath => ContextBasePath;
181184
}

managed/src/SwiftlyS2.Shared/ISwiftlyCore.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,4 +126,9 @@ public interface ISwiftlyCore {
126126
/// Registrator service.
127127
/// </summary>
128128
public IRegistratorService Registrator { get; }
129+
130+
/// <summary>
131+
/// Gets the file path to the plugin directory.
132+
/// </summary>
133+
public string PluginPath { get; }
129134
}

0 commit comments

Comments
 (0)