Skip to content

Commit

Permalink
Increment to 0.11.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Jbob committed Jun 19, 2016
1 parent d44d243 commit 2212ee4
Show file tree
Hide file tree
Showing 26 changed files with 133 additions and 107 deletions.
6 changes: 6 additions & 0 deletions Debugger/obj/Debug/Debugger.csproj.FileListAbsolute.txt
Expand Up @@ -18,3 +18,9 @@ D:\fog\client\Debugger\bin\x86\Debug\Modules.pdb
D:\fog\client\Debugger\bin\x86\Debug\Newtonsoft.Json.xml
D:\fog\client\Debugger\bin\x86\Debug\PipeServer.pdb
D:\fog\client\Debugger\bin\x86\Debug\PipeClient.pdb
C:\Users\Administrator\dev\fog-client\bin\Debugger.exe.config
C:\Users\Administrator\dev\fog-client\bin\Debugger.exe
C:\Users\Administrator\dev\fog-client\bin\Debugger.pdb
C:\Users\Administrator\dev\fog-client\Debugger\obj\Debug\Debugger.csprojResolveAssemblyReference.cache
C:\Users\Administrator\dev\fog-client\Debugger\obj\Debug\Debugger.exe
C:\Users\Administrator\dev\fog-client\Debugger\obj\Debug\Debugger.pdb
2 changes: 2 additions & 0 deletions Debugger/obj/Release/Debugger.csproj.FileListAbsolute.txt
Expand Up @@ -16,3 +16,5 @@ D:\fog\fog-client\bin\Debugger.exe.config
D:\fog\fog-client\bin\Debugger.exe
D:\fog\fog-client\Debugger\obj\Release\Debugger.csprojResolveAssemblyReference.cache
D:\fog\fog-client\Debugger\obj\Release\Debugger.exe
C:\Users\Administrator\dev\fog-client\bin\Debugger.exe.config
C:\Users\Administrator\dev\fog-client\Debugger\obj\Release\Debugger.exe
2 changes: 2 additions & 0 deletions FOGService.sln.DotSettings
@@ -0,0 +1,2 @@
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=FOG/@EntryIndexedValue">FOG</s:String></wpf:ResourceDictionary>
3 changes: 3 additions & 0 deletions MSI/Files.wxs
Expand Up @@ -54,6 +54,9 @@
<File Id="SuperWebSocket" Name="SuperWebSocket.dll" Source="..\bin\SuperWebSocket.dll" />
<File Id="WebSocket4Net" Name="WebSocket4Net.dll" Source="..\bin\WebSocket4Net.dll" />
<File Id="ProcessPrivileges" Name="ProcessPrivileges.dll" Source="..\bin\ProcessPrivileges.dll" />
<File Id="CommonLoggingCore" Name="Common.Logging.Core.dll" Source="..\bin\Common.Logging.Core.dll" />
<File Id="CommonLogging" Name="Common.Logging.dll" Source="..\bin\Common.Logging.dll" />
<File Id="Quartz" Name="Quartz.dll" Source="..\bin\Quartz.dll" />

<File Id="FOGShutdownGUIconf" Name="FOGShutdownGUI.exe.config" Source="..\bin\FOGShutdownGUI.exe.config" />
<File Id="FOGTrayconf" Name="FOGTray.exe.config" Source="..\bin\FOGTray.exe.config" />
Expand Down
4 changes: 2 additions & 2 deletions MSI/Product.wxs
Expand Up @@ -20,14 +20,14 @@
-->

<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:iis="http://schemas.microsoft.com/wix/IIsExtension">
<Product Id="*" Name="FOG Service" Language="1033" Version="0.10.6" UpgradeCode="1CCFDEAF-53E9-43AC-AE18-F9F86CEFA4EA"
<Product Id="*" Name="FOG Service" Language="1033" Version="0.11.0" UpgradeCode="1CCFDEAF-53E9-43AC-AE18-F9F86CEFA4EA"
Manufacturer="FOG">
<Package Description="FOG Service" Comments="A client for the FOG project" InstallerVersion="300" Compressed="yes"
InstallScope="perMachine" />
<!-- Remove old versions -->
<Upgrade Id="1CCFDEAF-53E9-43AC-AE18-F9F86CEFA4EA">
<UpgradeVersion OnlyDetect="yes" Minimum="0.0.0" Property="NEWERVERSIONDETECTED" IncludeMinimum="no" />
<UpgradeVersion OnlyDetect="no" Minimum="0.0.0" Maximum="0.10.5" Property="OLDERVERSIONBEINGUPGRADED"
<UpgradeVersion OnlyDetect="no" Minimum="0.0.0" Maximum="0.10.6" Property="OLDERVERSIONBEINGUPGRADED"
IncludeMinimum="no" IncludeMaximum="yes" MigrateFeatures="yes" />
</Upgrade>
<InstallExecuteSequence>
Expand Down
10 changes: 5 additions & 5 deletions Modules/DisplayManager/DisplayManager.cs
Expand Up @@ -49,11 +49,11 @@ protected override void DoWork(Response data, DisplayMessage msg)
_display.LoadDisplaySettings();
if (_display.PopulatedSettings)
{
//Get task info
var response = Communication.GetResponse("/service/displaymanager.php", true);

if (response.Error) return;

if (msg.X <= 0 || msg.Y <= 0)
{
Log.Error(Name, "Invalid settings provided");
return;
}
ChangeResolution(GetDisplays().Count > 0 ? GetDisplays()[0] : "", msg.X, msg.Y, msg.R);
}
else
Expand Down
3 changes: 0 additions & 3 deletions Modules/Modules.csproj
Expand Up @@ -160,9 +160,6 @@
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="job_scheduling_data_2_0.xsd">
<SubType>Designer</SubType>
</None>
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
Expand Down
5 changes: 2 additions & 3 deletions Modules/PrinterManager/DefaultPrinterManager.cs
Expand Up @@ -34,7 +34,7 @@ public class DefaultPrinterManager : AbstractModule<DefaultPrinterMessage>

public DefaultPrinterManager()
{
Name = "PrinterManager";
Name = "DefaultPrinterManager";

switch (Settings.OS)
{
Expand All @@ -49,8 +49,7 @@ public DefaultPrinterManager()

protected override void DoWork(Response data, DefaultPrinterMessage msg)
{
//Get printers
if (data.Error || string.IsNullOrWhiteSpace(msg.Name)) return;
if (string.IsNullOrEmpty(msg.Name)) return;

Log.Entry(Name, "Checking defaults");
var printer = new Printer {Name = msg.Name};
Expand Down
10 changes: 3 additions & 7 deletions Modules/PrinterManager/PrinterManager.cs
Expand Up @@ -57,17 +57,15 @@ public PrinterManager()

protected override void DoWork(Response data, PrinterMessage msg)
{

Log.Entry(Name, "Getting installed printers");
var installedPrinters = _instance.GetPrinters();


var printerAdded = false;

//Get printers
if (msg.Mode.Equals("0")) return;
if (msg.Mode == "0") return;

if (data.Error && data.ReturnCode.Equals("np"))
if (data.Error && data.ReturnCode.Equals("np", StringComparison.OrdinalIgnoreCase))
{
RemoveExtraPrinters(new List<Printer>(), msg, installedPrinters);
return;
Expand All @@ -81,8 +79,6 @@ protected override void DoWork(Response data, PrinterMessage msg)

RemoveExtraPrinters(msg.Printers, msg, installedPrinters);



Log.Entry(Name, "Adding printers");
foreach (var printer in msg.Printers)
{
Expand All @@ -108,7 +104,7 @@ private void RemoveExtraPrinters(List<Printer> newPrinters, PrinterMessage msg,
{
var managedPrinters = newPrinters.Where(printer => printer != null).Select(printer => printer.Name).ToList();

if (!msg.Mode.Equals("ar"))
if (!msg.Mode.Equals("ar", StringComparison.OrdinalIgnoreCase))
{
foreach (var name in msg.AllPrinters.Where(name => !managedPrinters.Contains(name) && existingPrinters.Contains(name)))
CleanPrinter(name, true);
Expand Down
114 changes: 39 additions & 75 deletions PrinterManagerHelper/Form1.Designer.cs

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

2 changes: 1 addition & 1 deletion PrinterManagerHelper/Form1.cs
@@ -1,6 +1,6 @@
/*
* FOG Service : A computer management client for the FOG Project
* Copyright (C) 2014-2015 FOG Project
* Copyright (C) 2014-2016 FOG Project
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
Expand Down
6 changes: 3 additions & 3 deletions Service/FOGSystemService.cs
Expand Up @@ -67,9 +67,9 @@ protected override Response GetLoopData()
Settings.Set("DefaultPrinter", (pDefault == null) ? "" : pDefault.GetField("default"));

var display = response.GetSubResponse("displaymanager");
Settings.Set("DisplayX", (display == null) ? "0" : display.GetField("x"));
Settings.Set("DisplayY", (display == null) ? "0" : display.GetField("y"));
Settings.Set("DisplayR", (display == null) ? "0" : display.GetField("r"));
Settings.Set("DisplayX", (display == null || display.Error) ? "" : display.GetField("x"));
Settings.Set("DisplayY", (display == null || display.Error) ? "" : display.GetField("y"));
Settings.Set("DisplayR", (display == null || display.Error) ? "" : display.GetField("r"));
}
catch (Exception ex)
{
Expand Down
6 changes: 6 additions & 0 deletions Service/obj/Debug/Service.csproj.FileListAbsolute.txt
Expand Up @@ -27,3 +27,9 @@ D:\fog\client\Service\bin\x86\Debug\Modules.pdb
D:\fog\client\Service\bin\x86\Debug\PipeServer.pdb
D:\fog\client\Service\bin\x86\Debug\FOGUpdateHelper.pdb
D:\fog\client\Service\bin\x86\Debug\FOGUpdateWaiter.pdb
C:\Users\Administrator\dev\fog-client\bin\FOGService.exe.config
C:\Users\Administrator\dev\fog-client\bin\FOGService.exe
C:\Users\Administrator\dev\fog-client\bin\FOGService.pdb
C:\Users\Administrator\dev\fog-client\Service\obj\Debug\Service.csprojResolveAssemblyReference.cache
C:\Users\Administrator\dev\fog-client\Service\obj\Debug\FOGService.exe
C:\Users\Administrator\dev\fog-client\Service\obj\Debug\FOGService.pdb
9 changes: 9 additions & 0 deletions Tray/obj/Debug/Tray.csproj.FileListAbsolute.txt
Expand Up @@ -12,3 +12,12 @@ C:\Users\jbob\Desktop\fog-client\Tray\obj\Debug\FOG.NotificationIcon.resources
C:\Users\jbob\Desktop\fog-client\Tray\obj\Debug\Tray.csproj.GenerateResource.Cache
C:\Users\jbob\Desktop\fog-client\Tray\obj\Debug\FOGTray.exe
C:\Users\jbob\Desktop\fog-client\Tray\obj\Debug\FOGTray.pdb
C:\Users\Administrator\dev\fog-client\bin\logo.ico
C:\Users\Administrator\dev\fog-client\bin\FOGTray.exe.config
C:\Users\Administrator\dev\fog-client\bin\FOGTray.exe
C:\Users\Administrator\dev\fog-client\bin\FOGTray.pdb
C:\Users\Administrator\dev\fog-client\Tray\obj\Debug\Tray.csprojResolveAssemblyReference.cache
C:\Users\Administrator\dev\fog-client\Tray\obj\Debug\FOG.NotificationIcon.resources
C:\Users\Administrator\dev\fog-client\Tray\obj\Debug\Tray.csproj.GenerateResource.Cache
C:\Users\Administrator\dev\fog-client\Tray\obj\Debug\FOGTray.exe
C:\Users\Administrator\dev\fog-client\Tray\obj\Debug\FOGTray.pdb
2 changes: 2 additions & 0 deletions Tray/obj/Release/Tray.csproj.FileListAbsolute.txt
Expand Up @@ -20,3 +20,5 @@ D:\fog\fog-client\bin\FOGTray.exe.config
D:\fog\fog-client\bin\FOGTray.exe
D:\fog\fog-client\Tray\obj\Release\Tray.csprojResolveAssemblyReference.cache
D:\fog\fog-client\Tray\obj\Release\FOGTray.exe
C:\Users\Administrator\dev\fog-client\bin\FOGTray.exe.config
C:\Users\Administrator\dev\fog-client\Tray\obj\Release\FOGTray.exe
2 changes: 1 addition & 1 deletion UniversalInstaller/Helper.cs
Expand Up @@ -28,7 +28,7 @@ namespace FOG
public static class Helper
{
private const string LogName = "Installer";
public const string ClientVersion = "0.10.6";
public const string ClientVersion = "0.11.0";

public static IInstall Instance { get; }

Expand Down
9 changes: 9 additions & 0 deletions UniversalInstaller/UniversalInstaller.cs
Expand Up @@ -47,6 +47,7 @@ static void Main(string[] args)
var https = false;
var server = "";
var webRoot = "";
var logFile = "";

var p = new OptionSet() {
{ "server=|SERVER=", "the FOG server address, defaults to fogserver",
Expand All @@ -65,10 +66,18 @@ static void Main(string[] args)
v => uninstall = v != null },
{ "upgrade", "upgrade an existing installation",
v => upgrade = v != null },
{ "l|log", "the log file to use",
v => logFile = v },
};

p.Parse(args);

if (!string.IsNullOrWhiteSpace(logFile))
{
LogPath = logFile;
Log.FilePath = LogPath;
}

if (args.Length == 1)
{
if (args[0].Equals("upgrade"))
Expand Down
2 changes: 1 addition & 1 deletion UpdateHelper/AbstractUpdate.cs
Expand Up @@ -27,7 +27,7 @@ abstract class AbstractUpdate : IUpdate
{
public void ApplyUpdate()
{
ProcessHandler.RunClientEXE("SmartInstaller.exe", "--upgrade");
ProcessHandler.RunClientEXE("SmartInstaller.exe", $"/upgrade /log=\"{Log.FilePath}\"");
}

public abstract void StartService();
Expand Down

0 comments on commit 2212ee4

Please sign in to comment.