@@ -85,8 +85,8 @@ const struct option long_options[] = {
8585
8686void short_usage (char *arg0)
8787{
88- throw std::runtime_error{" Usage error. For further information see: \n "
89- " \t {} -h|-- help\n " _format (program_name (arg0))};
88+ throw std::runtime_error{" Usage error. For further information call: "
89+ " {} -- help" _format (program_name (arg0))};
9090}
9191
9292void long_usage (char const *arg0, bool verbose)
@@ -335,17 +335,17 @@ static osmium::Box parse_bbox(char const *bbox)
335335 int const n = sscanf (bbox, " %lf,%lf,%lf,%lf" , &minx, &miny, &maxx, &maxy);
336336 if (n != 4 ) {
337337 throw std::runtime_error{" Bounding box must be specified like: "
338- " minlon,minlat,maxlon,maxlat\n " };
338+ " minlon,minlat,maxlon,maxlat. " };
339339 }
340340
341341 if (maxx <= minx) {
342342 throw std::runtime_error{
343- " Bounding box failed due to maxlon <= minlon\n " };
343+ " Bounding box failed due to maxlon <= minlon. " };
344344 }
345345
346346 if (maxy <= miny) {
347347 throw std::runtime_error{
348- " Bounding box failed due to maxlat <= minlat\n " };
348+ " Bounding box failed due to maxlat <= minlat. " };
349349 }
350350
351351 fmt::print (stderr, " Applying Bounding box: {},{} to {},{}\n " , minx, miny,
@@ -445,7 +445,7 @@ options_t::options_t(int argc, char *argv[]) : options_t()
445445 if (!optarg || optarg[0 ] == ' -' ) {
446446 throw std::runtime_error{
447447 " Missing argument for option --expire-tiles. Zoom "
448- " levels must be positive.\n " };
448+ " levels must be positive." };
449449 }
450450 char *next_char;
451451 expire_tiles_zoom_min =
@@ -454,7 +454,7 @@ options_t::options_t(int argc, char *argv[]) : options_t()
454454 throw std::runtime_error{
455455 " Bad argument for option --expire-tiles. "
456456 " Minimum zoom level must be larger "
457- " than 0.\n " };
457+ " than 0." };
458458 }
459459 // The first character after the number is ignored because that is the separating hyphen.
460460 if (*next_char == ' -' ) {
@@ -466,19 +466,19 @@ options_t::options_t(int argc, char *argv[]) : options_t()
466466 std::strtoul (next_char, &after_maxzoom, 10 ));
467467 if (expire_tiles_zoom == 0 || *after_maxzoom != ' \0 ' ) {
468468 throw std::runtime_error{" Invalid maximum zoom level "
469- " given for tile expiry.\n " };
469+ " given for tile expiry." };
470470 }
471471 } else {
472472 throw std::runtime_error{
473- " Invalid maximum zoom level given for tile expiry.\n " };
473+ " Invalid maximum zoom level given for tile expiry." };
474474 }
475475 } else if (*next_char == ' \0 ' ) {
476476 // end of string, no second zoom level given
477477 expire_tiles_zoom = expire_tiles_zoom_min;
478478 } else {
479479 throw std::runtime_error{" Minimum and maximum zoom level for "
480480 " tile expiry must be separated by "
481- " '-'.\n " };
481+ " '-'." };
482482 }
483483 break ;
484484 case ' o' :
@@ -501,7 +501,7 @@ options_t::options_t(int argc, char *argv[]) : options_t()
501501 case ' k' :
502502 if (hstore_mode != hstore_column::none) {
503503 throw std::runtime_error{" You can not specify both --hstore "
504- " (-k) and --hstore-all (-j)\n " };
504+ " (-k) and --hstore-all (-j). " };
505505 }
506506 hstore_mode = hstore_column::norm;
507507 break ;
@@ -511,7 +511,7 @@ options_t::options_t(int argc, char *argv[]) : options_t()
511511 case ' j' :
512512 if (hstore_mode != hstore_column::none) {
513513 throw std::runtime_error{" You can not specify both --hstore "
514- " (-k) and --hstore-all (-j)\n " };
514+ " (-k) and --hstore-all (-j). " };
515515 }
516516 hstore_mode = hstore_column::all;
517517 break ;
@@ -543,7 +543,7 @@ options_t::options_t(int argc, char *argv[]) : options_t()
543543 alloc_chunkwise = ALLOC_DENSE | ALLOC_SPARSE;
544544 } else {
545545 throw std::runtime_error{
546- " Unrecognized cache strategy {}.\n " _format (optarg)};
546+ " Unrecognized cache strategy {}." _format (optarg)};
547547 }
548548 break ;
549549 case 205 :
@@ -641,15 +641,15 @@ void options_t::check_options()
641641{
642642 if (append && create) {
643643 throw std::runtime_error{" --append and --create options can not be "
644- " used at the same time!\n " };
644+ " used at the same time!" };
645645 }
646646
647647 if (append && !slim) {
648- throw std::runtime_error{" --append can only be used with slim mode!\n " };
648+ throw std::runtime_error{" --append can only be used with slim mode!" };
649649 }
650650
651651 if (droptemp && !slim) {
652- throw std::runtime_error{" --drop only makes sense with --slim.\n " };
652+ throw std::runtime_error{" --drop only makes sense with --slim." };
653653 }
654654
655655 if (hstore_mode == hstore_column::none && hstore_columns.empty () &&
@@ -676,7 +676,7 @@ void options_t::check_options()
676676 if (cache == 0 ) {
677677 if (!slim) {
678678 throw std::runtime_error{
679- " Ram node cache can only be disable in slim mode.\n " };
679+ " Ram node cache can only be disable in slim mode." };
680680 }
681681 if (!flat_node_cache_enabled) {
682682 fprintf (stderr, " WARNING: ram cache is disabled. This will likely "
0 commit comments