Skip to content

Commit

Permalink
Branding & compilation cleanups
Browse files Browse the repository at this point in the history
  • Loading branch information
vulpesfox committed Jun 10, 2019
1 parent 38111e2 commit a0a8e70
Show file tree
Hide file tree
Showing 20 changed files with 57 additions and 15 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -272,3 +272,5 @@ Vulpes_Main.cer

AutoVersion.cs
Licenses.licx

INSTALL/CD
15 changes: 15 additions & 0 deletions Branding.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
using System;
namespace System
{
public static class VulpesBranding
{
public const string BuiltInOnPremURL = "https://sdc.your-own-url-for-service.lu/sdc";
public const string MSIGUID = "{A6F066EE-E795-4C65-8FE4-2D93AB52BC36}";
public const string AgentUITitle = "Fox SDC Agent";
public const string AgentUIMutex = "Fox-SDC-AgentMutex-FFE87757-F4A8-4F21-AE70-BD31A9D696A2";
public const string MGMTTitle = "Fox SDC";
public const string PKGTitle = "Fox SDC Package Creator";
public const string REDIRTitle = "Fox SDC Redirection Console";
public const string REMOTECONNTitle = "Fox SDC Remote Connect";
}
}
2 changes: 2 additions & 0 deletions Fox Software Deployment and Control.sln
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,11 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{57A7E4B0-129F-4F49-98F1-23595E148D3C}"
ProjectSection(SolutionItems) = preProject
INSTALL\all.cmd = INSTALL\all.cmd
Branding.cs = Branding.cs
INSTALL\collect.cmd = INSTALL\collect.cmd
LICENSE = LICENSE
README.md = README.md
INSTALL\initvars.cmd = INSTALL\initvars.cmd
Registry Tricks.txt = Registry Tricks.txt
INSTALL\SDCA.foxps = INSTALL\SDCA.foxps
signall.cmd = signall.cmd
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_Agent/FoxSDC_Agent.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="ApplicationCertificate.cs" />
<Compile Include="AutoVersion.cs" />
<Compile Include="DownloadSystemFSData.cs" />
Expand Down
8 changes: 4 additions & 4 deletions FoxSDC_Agent/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace FoxSDC_Agent
public class ProgramAgent
{
public static CPPInterface CPP;
public const string VulpesURL = "https://fox-sdc.vulpes.lu/sdc";
public const string VulpesURL = VulpesBranding.BuiltInOnPremURL;
public static string AppPath;
public static string DLLFile;

Expand Down Expand Up @@ -203,11 +203,11 @@ public static void SMain()

if (UsePipeAction == false && UseScreenAction == false)
{
using (RegistryKey installer = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\{A6F066EE-E795-4C65-8FE4-2D93AB52BC36}", false))
using (RegistryKey installer = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\" + VulpesBranding.MSIGUID, false))
{
if (installer == null)
{
FoxEventLog.WriteEventLog("Missing installer key in HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\{A6F066EE-E795-4C65-8FE4-2D93AB52BC36}. This can lead to erratic behavoir of the program!", EventLogEntryType.Warning);
FoxEventLog.WriteEventLog("Missing installer key in HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\" + VulpesBranding.MSIGUID + ". This can lead to erratic behavoir of the program!", EventLogEntryType.Warning);
}
}

Expand Down Expand Up @@ -305,7 +305,7 @@ public static void SMain()
}

try
{
{
using (RegistryKey reg = Registry.LocalMachine.OpenSubKey("Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System", true))
{
object o = reg.GetValue("SoftwareSASGeneration", null);
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_Agent_UI/FoxSDC_Agent_UI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="About.cs">
<SubType>Form</SubType>
</Compile>
Expand Down
4 changes: 2 additions & 2 deletions FoxSDC_Agent_UI/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace FoxSDC_Agent_UI
{
static class Program
{
public static string AppTitle = "Fox SDC Agent";
public static string AppTitle = VulpesBranding.AgentUITitle;
public static MainDLG MainDLG = null;
public static frmChat Chat = null;
public static frmNT3Icon NT3 = null;
Expand Down Expand Up @@ -44,7 +44,7 @@ static void Main(string[] args)
if (QuitApp == true)
return;

using (Mutex mutex = new Mutex(false, "Local\\Fox-SDC-AgentMutex-FFE87757-F4A8-4F21-AE70-BD31A9D696A2"))
using (Mutex mutex = new Mutex(false, "Local\\" + VulpesBranding.AgentUIMutex))
{
if (!mutex.WaitOne(0, false))
{
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_MGMT/FoxSDC_MGMT.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="AddFilesFromRemoteClient.cs">
<SubType>Form</SubType>
</Compile>
Expand Down
3 changes: 1 addition & 2 deletions FoxSDC_MGMT/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public static void LoadImageList(ImageList imageList)
[STAThread]
static int Main(string[] args)
{
Title = "Fox SDC " + Version;
Title = VulpesBranding.MGMTTitle + " " + Version;

if (args.Length > 1)
{
Expand All @@ -70,7 +70,6 @@ static int Main(string[] args)
}
}


Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new MainDLG());
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_PackageCreator/FoxSDC_PackageCreator.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="AskText.cs">
<SubType>Form</SubType>
</Compile>
Expand Down
2 changes: 1 addition & 1 deletion FoxSDC_PackageCreator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace FoxSDC_PackageCreator
{
static class Program
{
public static string AppTitle = "Fox SDC Package Creator";
public static string AppTitle = VulpesBranding.PKGTitle;
public static string AppPath = "";

public static void LoadImageList(ImageList imageList)
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_RedirConsole/FoxSDC_RedirConsole.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="AutoVersion.cs" />
<Compile Include="FormExtender.cs">
<SubType>Form</SubType>
Expand Down
2 changes: 1 addition & 1 deletion FoxSDC_RedirConsole/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ private static void Console_CancelKeyPress(object sender, ConsoleCancelEventArgs

static void Main(string[] args)
{
Console.WriteLine("Fox SDC Redirection Console");
Console.WriteLine(VulpesBranding.REDIRTitle);

if (Console.IsErrorRedirected == true || Console.IsInputRedirected == true || Console.IsOutputRedirected == true)
{
Expand Down
3 changes: 3 additions & 0 deletions FoxSDC_RemoteConnect/FoxSDC_RemoteConnect.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\Branding.cs">
<Link>Branding.cs</Link>
</Compile>
<Compile Include="AutoVersion.cs" />
<Compile Include="FormExtender.cs">
<SubType>Form</SubType>
Expand Down
2 changes: 1 addition & 1 deletion FoxSDC_RemoteConnect/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace FoxSDC_RemoteConnect
{
static class Program
{
public static string Title = "Fox SDC Remote Connect";
public static string Title = VulpesBranding.REMOTECONNTitle;
public static Network net;

public static string Connection = "";
Expand Down
Binary file added INSTALL/SDCA.foxpkg
Binary file not shown.
5 changes: 4 additions & 1 deletion INSTALL/all.cmd
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
call initvars.cmd

cd ..
call msbuild "Fox Software Deployment and Control.sln" /property:Configuration=Release
timeout 10
call signall.cmd
cd INSTALL
call collect.cmd
call collect.cmd

4 changes: 2 additions & 2 deletions INSTALL/collect.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ call msbuild "FoxSDC_Agent_Setup64\FoxSDC_Agent_Setup64.wixproj" /property:Confi
copy "FoxSDC_Agent_Setup64\bin\x64\Release\FoxSDC_Agent_Setup.msi" "CD\FoxSDC_Agent_Setup64.msi"
copy "FoxSDC_Agent_Setup32\bin\Release\FoxSDC_Agent_Setup.msi" "CD\FoxSDC_Agent_Setup32.msi"

call signtool sign /sha1 BLAHBLAH "CD\FoxSDC_Agent_Setup32.msi" "CD\FoxSDC_Agent_Setup64.msi"
call "CD\SDC Tools\FoxSDC_PackageCreatorC.exe" compile SDCA.foxps csp "opensc csp"
call signtool sign /sha1 %SHACERT% "CD\FoxSDC_Agent_Setup32.msi" "CD\FoxSDC_Agent_Setup64.msi"
call "CD\SDC Tools\FoxSDC_PackageCreatorC.exe" compile SDCA.foxps %PKG%

copy SDCA.foxpkg "CD"

Expand Down
3 changes: 3 additions & 0 deletions INSTALL/initvars.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
SET SHACERT=48b804f3d3be6c5f06e72d94be29b10601b2d820
SET PKG=CERT "CN=GitHub Test - Vulpes Main"

2 changes: 1 addition & 1 deletion signall.cmd
Original file line number Diff line number Diff line change
@@ -1 +1 @@
signtool sign /sha1 BLAHBLAH Release\FoxSDC_Agent.exe Release\FoxSDC_Agent_UI.exe Release\FoxSDC_AgentDLL32.dll Release\FoxSDC_AgentDLL64.dll Release\FoxSDC_ApplyUserSettings.exe Release\FoxSDC_Common.dll Release\FoxSDC_MGMT.exe Release\FoxSDC_PackageCreator.exe Release\FoxSDC_Selfupdate.exe Release\FoxSDC_Server.exe Release\FoxSDC_UninstallData.exe Release\MyUCID.exe Release\FoxSDC_Configure.exe Release\FoxSDC_PackageCreatorC.exe Release\FoxSDC_RedirConsole.exe Release\FoxSDC_RemoteConnect.exe Release\FoxSDC_ManageScreen.exe Release\FoxSDC_SAS32.dll Release\FoxSDC_SAS64.dll
signtool sign /sha1 %SHACERT% Release\FoxSDC_Agent.exe Release\FoxSDC_Agent_UI.exe Release\FoxSDC_AgentDLL32.dll Release\FoxSDC_AgentDLL64.dll Release\FoxSDC_ApplyUserSettings.exe Release\FoxSDC_Common.dll Release\FoxSDC_MGMT.exe Release\FoxSDC_PackageCreator.exe Release\FoxSDC_Selfupdate.exe Release\FoxSDC_Server.exe Release\FoxSDC_UninstallData.exe Release\MyUCID.exe Release\FoxSDC_Configure.exe Release\FoxSDC_PackageCreatorC.exe Release\FoxSDC_RedirConsole.exe Release\FoxSDC_RemoteConnect.exe Release\FoxSDC_ManageScreen.exe Release\FoxSDC_SAS32.dll Release\FoxSDC_SAS64.dll

0 comments on commit a0a8e70

Please sign in to comment.