Skip to content

Commit

Permalink
feat!: first major release 1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jdaar committed May 11, 2023
1 parent 3e9ee6b commit 803d2b0
Show file tree
Hide file tree
Showing 83 changed files with 222 additions and 37 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
5 changes: 5 additions & 0 deletions fsBuddyClient/Client.csproj → Client/Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<TargetFramework>net6.0-windows7.0</TargetFramework>
<Nullable>enable</Nullable>
<UseWPF>true</UseWPF>
<ApplicationIcon>fsbuddy_icon.ico</ApplicationIcon>
</PropertyGroup>

<ItemGroup>
Expand All @@ -27,6 +28,10 @@
<None Remove="Assets\source_code_pro.ttf" />
</ItemGroup>

<ItemGroup>
<Content Include="fsbuddy_icon.ico" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Ookii.Dialogs.Wpf" Version="5.0.1" />
</ItemGroup>
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public async Task Connect()
"fsbuddy-service",
PipeDirection.InOut,
PipeOptions.Asynchronous,
System.Security.Principal.TokenImpersonationLevel.Identification
System.Security.Principal.TokenImpersonationLevel.Impersonation

);
} catch (Exception e)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file added Client/fsbuddy_icon.ico
Binary file not shown.
File renamed without changes.
File renamed without changes.
File renamed without changes.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

37 changes: 37 additions & 0 deletions Configuration/Migrations/20230509054330_remove-service-settings.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace Configuration.Migrations
{
/// <inheritdoc />
public partial class removeservicesettings : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "system_settings");
}

/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "system_settings",
columns: table => new
{
id = table.Column<int>(type: "INTEGER", nullable: false)
.Annotation("Sqlite:Autoincrement", true),
created_at = table.Column<DateTime>(type: "TEXT", nullable: false),
type = table.Column<int>(type: "INTEGER", nullable: false),
value = table.Column<int>(type: "INTEGER", nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_system_settings", x => x.id);
});
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,31 +17,6 @@ protected override void BuildModel(ModelBuilder modelBuilder)
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "7.0.5");

modelBuilder.Entity("ConnectionInterface.ServiceSetting", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER")
.HasColumnName("id");
b.Property<DateTime>("CreatedAt")
.HasColumnType("TEXT")
.HasColumnName("created_at");
b.Property<int>("Type")
.HasColumnType("INTEGER")
.HasColumnName("type");
b.Property<int?>("Value")
.IsRequired()
.HasColumnType("INTEGER")
.HasColumnName("value");
b.HasKey("Id");
b.ToTable("system_settings");
});

modelBuilder.Entity("ConnectionInterface.Watcher", b =>
{
b.Property<int>("Id")
Expand Down Expand Up @@ -95,7 +70,7 @@ protected override void BuildModel(ModelBuilder modelBuilder)
b.HasKey("Id");
b.ToTable("watchers");
b.ToTable("watchers", (string)null);
});
#pragma warning restore 612, 618
}
Expand Down
Binary file added Installer/FsBuddySetup.exe
Binary file not shown.
56 changes: 56 additions & 0 deletions Installer/Setup.iss
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define MyAppName "FsBuddy"
#define MyAppVersion "1.0"
#define MyAppPublisher "Jhonatan David Asprilla Arango"
#define MyAppURL "https://alertbud.co/fsbuddy"
#define MyAppExeName "Client.exe"

[Setup]
; NOTE: The value of AppId uniquely identifies this application. Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{A90A4C64-1376-4636-9563-6FEB37396F1A}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={autopf}\{#MyAppName}
DisableProgramGroupPage=yes
; Remove the following line to run in administrative install mode (install for all users.)
PrivilegesRequired=admin
PrivilegesRequiredOverridesAllowed=commandline
OutputDir=C:\Users\root\source\repos\fsBuddy\Installer
OutputBaseFilename=FsBuddySetup
SetupIconFile=C:\Users\root\Downloads\fsbuddy_icon.ico
Compression=lzma
SolidCompression=yes
WizardStyle=modern
AlwaysRestart=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked

[Files]
Source: "C:\Users\root\source\repos\fsBuddy\Client\bin\Release\net6.0-windows7.0\{#MyAppExeName}"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Users\root\source\repos\fsBuddy\Client\bin\Release\net6.0-windows7.0\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
Source: "C:\Users\root\source\repos\fsBuddy\Service\bin\Release\net6.0\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
Name: "{autoprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon

[Run]
Filename: "{sys}\sc.exe"; Parameters: "create fsbuddy start=auto binPath=""{app}\Service.exe""" ; Flags: runhidden

[UninstallRun]
Filename: {sys}\sc.exe; Parameters: "stop fsbuddy" ; Flags: runhidden
Filename: {sys}\sc.exe; Parameters: "delete fsbuddy" ; Flags: runhidden
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@
using Serilog.Formatting.Compact;
using Serilog.Core;
using System.ComponentModel.Design;
using Microsoft.Extensions.Logging.EventLog;

namespace Service
{
class FileSystemService
{
private string appDirectoryPath;
private string logDirectoryPath;
private IHostBuilder _hostBuilder;
public IHostBuilder _hostBuilder;

private Logger LoggerFactory()
{
Expand Down Expand Up @@ -43,7 +44,8 @@ public FileSystemService()

Log.Logger = LoggerFactory();

_hostBuilder = Host.CreateDefaultBuilder()
_hostBuilder = Host
.CreateDefaultBuilder()
.ConfigureLogging(logging =>
{
logging.ClearProviders();
Expand All @@ -57,7 +59,17 @@ public FileSystemService()
services.AddSingleton<WatcherManager>();
services.AddHostedService(provider => provider.GetService<WatcherManager>());
});
if (OperatingSystem.IsWindows())
{
services.Configure<EventLogSettings>(config =>
{
config.LogName = "fsBuddy";
config.SourceName = "fsBuddy";
});
}
})
.UseWindowsService();
}

public async Task RunAsync()
Expand Down
File renamed without changes.
1 change: 0 additions & 1 deletion fsBuddyService/PipeManager.cs → Service/PipeManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ class PipeManager : BackgroundService
private StreamReader _reader;

const string PIPE_NAME = "fsbuddy-service";
const int PIPE_STREAM_END_BYTE = -1;

private Dictionary<t_PipeCommand, Func<PipeRequest, Task<PipeResponse>>> Handlers;

Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions fsBuddyService/Service.cs → Service/Service.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@
FileSystemService service = new FileSystemService();

await service.RunAsync();

5 changes: 3 additions & 2 deletions fsBuddyService/Service.csproj → Service/Service.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Hosting" Version="6.0.1" />
<PackageReference Include="Microsoft.Extensions.Hosting" Version="7.0.1" />
<PackageReference Include="Microsoft.Extensions.Hosting.WindowsServices" Version="7.0.0" />
<PackageReference Include="Serilog" Version="2.12.0" />
<PackageReference Include="Serilog.Extensions.Logging" Version="3.1.0" />
<PackageReference Include="Serilog.Formatting.Compact" Version="1.1.0" />
Expand All @@ -17,7 +18,7 @@
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\Configuration\Configuration.csproj" />
<ProjectReference Include="..\ConnectionInterface\ConnectionInterface.csproj" />
<ProjectReference Include="..\fsBuddyConfiguration\Configuration.csproj" />
</ItemGroup>
</Project>
File renamed without changes.
File renamed without changes.
File renamed without changes.
26 changes: 22 additions & 4 deletions fsBuddy.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,54 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.5.33424.131
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Service", "fsBuddyService\Service.csproj", "{98D2072C-58EC-441A-9635-D5B16F953E7A}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Service", "Service\Service.csproj", "{98D2072C-58EC-441A-9635-D5B16F953E7A}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Client", "fsBuddyClient\Client.csproj", "{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Client", "Client\Client.csproj", "{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Configuration", "fsBuddyConfiguration\Configuration.csproj", "{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Configuration", "Configuration\Configuration.csproj", "{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConnectionInterface", "ConnectionInterface\ConnectionInterface.csproj", "{F5D69ADF-9FB3-4447-89DA-829AD3639D05}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ConnectionInterface", "ConnectionInterface\ConnectionInterface.csproj", "{F5D69ADF-9FB3-4447-89DA-829AD3639D05}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Debug|x86.ActiveCfg = Debug|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Debug|x86.Build.0 = Debug|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Release|Any CPU.Build.0 = Release|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Release|x86.ActiveCfg = Release|Any CPU
{98D2072C-58EC-441A-9635-D5B16F953E7A}.Release|x86.Build.0 = Release|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Debug|x86.ActiveCfg = Debug|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Debug|x86.Build.0 = Debug|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Release|Any CPU.Build.0 = Release|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Release|x86.ActiveCfg = Release|Any CPU
{3C21D363-AFE4-4DFF-83D6-EE0966AABF41}.Release|x86.Build.0 = Release|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Debug|x86.ActiveCfg = Debug|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Debug|x86.Build.0 = Debug|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Release|Any CPU.Build.0 = Release|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Release|x86.ActiveCfg = Release|Any CPU
{D061A062-E8C6-4A12-89A2-F123F0B2ED0D}.Release|x86.Build.0 = Release|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Debug|x86.ActiveCfg = Debug|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Debug|x86.Build.0 = Debug|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Release|Any CPU.Build.0 = Release|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Release|x86.ActiveCfg = Release|Any CPU
{F5D69ADF-9FB3-4447-89DA-829AD3639D05}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down

0 comments on commit 803d2b0

Please sign in to comment.