Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
auto-tx
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
vamp
auto-tx
Commits
5353ea07
Commit
5353ea07
authored
7 years ago
by
Niko Ehrenfeuchter
Browse files
Options
Downloads
Patches
Plain Diff
Make StartupSummary() print one message instead of many small ones.
parent
9c75a68b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
AutoTx/AutoTx.cs
+9
-11
9 additions, 11 deletions
AutoTx/AutoTx.cs
with
9 additions
and
11 deletions
AutoTx/AutoTx.cs
+
9
−
11
View file @
5353ea07
...
...
@@ -190,7 +190,7 @@ namespace AutoTx
/// Write a summary of loaded config + status to the log.
/// </summary>
private
void
StartupSummary
()
{
var
msg
=
"\n\n------ RoboSharp ------\n"
;
var
msg
=
"
Startup Summary:
\n\n------ RoboSharp ------\n"
;
var
roboDll
=
System
.
Reflection
.
Assembly
.
GetAssembly
(
typeof
(
RoboCommand
)).
Location
;
if
(
roboDll
!=
null
)
{
var
versionInfo
=
FileVersionInfo
.
GetVersionInfo
(
roboDll
);
...
...
@@ -198,27 +198,24 @@ namespace AutoTx
" > DLL description: "
+
versionInfo
.
Comments
+
"\n"
+
" > DLL version: "
+
versionInfo
.
FileVersion
+
"\n"
;
}
writeLogDebug
(
msg
);
msg
=
"\n\n------ Loaded status flags ------\n"
+
_status
.
Summary
()
+
"\n------ Loaded configuration settings ------\n"
+
_config
.
Summary
();
writeLogDebug
(
msg
);
msg
+=
"\n------ Loaded status flags ------\n"
+
_status
.
Summary
()
+
"\n------ Loaded configuration settings ------\n"
+
_config
.
Summary
();
msg
=
"\n
\n
------ Current system parameters ------\n"
+
"Hostname: "
+
Environment
.
MachineName
+
"\n"
+
"Free system memory: "
+
GetFreeMemory
()
+
" MB"
+
"\n"
;
msg
+
=
"\n------ Current system parameters ------\n"
+
"Hostname: "
+
Environment
.
MachineName
+
"\n"
+
"Free system memory: "
+
GetFreeMemory
()
+
" MB"
+
"\n"
;
foreach
(
var
driveToCheck
in
_config
.
SpaceMonitoring
)
{
msg
+=
"Free space on drive '"
+
driveToCheck
.
DriveName
+
"': "
+
GetFreeDriveSpace
(
driveToCheck
.
DriveName
)
+
"\n"
;
}
writeLogDebug
(
msg
);
writeLogDebug
(
"
------ Grace location status ------"
)
;
msg
+=
"\n
------ Grace location status ------
\n
"
;
try
{
Check
GraceLocation
();
msg
+=
GraceLocation
Summary
();
}
catch
(
Exception
ex
)
{
writeLog
(
"CheckGraceLocation() failed: "
+
ex
.
Message
,
true
);
...
...
@@ -232,6 +229,7 @@ namespace AutoTx
writeLog
(
"WARNING: some status parameters were invalid and have been reset:\n"
+
_status
.
ValidationWarnings
);
}
writeLogDebug
(
msg
);
}
#
endregion
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment