The Gitlab instance will be restarted on Monday April 28th at 2AM. There will be a short interruption of service.

Skip to content
Snippets Groups Projects
Commit 33505585 authored by Demian Katz's avatar Demian Katz
Browse files

Improved some messaging.

parent 7426585e
No related merge requests found
...@@ -324,19 +324,24 @@ class UtilController extends AbstractBase ...@@ -324,19 +324,24 @@ class UtilController extends AbstractBase
// No filename specified? Give usage guidelines: // No filename specified? Give usage guidelines:
if (empty($filename)) { if (empty($filename)) {
Console::writeLine("Delete records from VuFind's index."); Console::writeLine("Delete records from VuFind's index.");
Console::writeLine(""); Console::writeLine('');
Console::writeLine("Usage: deletes.php [filename] [format] [index]"); Console::writeLine(
Console::writeLine(""); 'Usage: deletes.php [--verbose] FILENAME FORMAT INDEX'
);
Console::writeLine('');
Console::writeLine( Console::writeLine(
"[filename] is the file containing records to delete." 'The optional --verbose switch turns on detailed feedback.'
); );
Console::writeLine( Console::writeLine(
"[format] is the format of the file -- " 'FILENAME is the file containing records to delete.'
. "it may be one of the following:" );
Console::writeLine(
'FORMAT is the format of the file -- '
. 'it may be one of the following:'
); );
Console::writeLine( Console::writeLine(
"\tflat - flat text format " "\tflat - flat text format "
. "(deletes all IDs in newline-delimited file)" . '(deletes all IDs in newline-delimited file)'
); );
Console::writeLine( Console::writeLine(
"\tmarc - binary MARC format (delete all record IDs from 001 fields)" "\tmarc - binary MARC format (delete all record IDs from 001 fields)"
...@@ -347,7 +352,7 @@ class UtilController extends AbstractBase ...@@ -347,7 +352,7 @@ class UtilController extends AbstractBase
Console::writeLine( Console::writeLine(
'"marc" is used by default if no format is specified.' '"marc" is used by default if no format is specified.'
); );
Console::writeLine("[index] is the index to use (default = Solr)"); Console::writeLine('INDEX is the index to use (default = Solr)');
return $this->getFailureResponse(); return $this->getFailureResponse();
} }
...@@ -387,7 +392,7 @@ class UtilController extends AbstractBase ...@@ -387,7 +392,7 @@ class UtilController extends AbstractBase
$missingIdCount++; $missingIdCount++;
} }
} }
if ($verbose) { if ($verbose && $missingIdCount) {
Console::writeLine( Console::writeLine(
"Encountered $missingIdCount record(s) without IDs." "Encountered $missingIdCount record(s) without IDs."
); );
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment