run: add colon before printing started units
authorIago López Galeiras <iago@kinvolk.io>
Mon, 4 Apr 2016 09:28:14 +0000 (11:28 +0200)
committerIago López Galeiras <iago@kinvolk.io>
Mon, 4 Apr 2016 09:28:14 +0000 (11:28 +0200)
In 110ceee58e5bc796c03a7db2109f85a999d5bc2e we removed the period after
printing the started units. This makes copying the unit name easier but
results in improper English.

This adds a colon before printing the units, which makes the output
look better.

man/systemd-run.xml
src/run/run.c

index a92dfb4..473f83e 100644 (file)
     provided by systemd to services:</para>
 
     <programlisting># systemd-run env
-Running as unit run-19945.service
+Running as unit: run-19945.service
 # journalctl -u run-19945.service
 Sep 08 07:37:21 bupkis systemd[1]: Starting /usr/bin/env...
 Sep 08 07:37:21 bupkis systemd[1]: Started /usr/bin/env.
@@ -366,8 +366,8 @@ Sep 08 07:37:21 bupkis env[19948]: BOOT_IMAGE=/vmlinuz-3.11.0-0.rc5.git6.2.fc20.
 
     <programlisting># date; systemd-run --on-active=30 --timer-property=AccuracySec=100ms /bin/touch /tmp/foo
 Mon Dec  8 20:44:24 KST 2014
-Running as unit run-71.timer
-Will run service as unit run-71.service
+Running as unit: run-71.timer
+Will run service as unit: run-71.service
 # journalctl -b -u run-71.timer
 -- Logs begin at Fri 2014-12-05 19:09:21 KST, end at Mon 2014-12-08 20:44:54 KST. --
 Dec 08 20:44:38 container systemd[1]: Starting /bin/touch /tmp/foo.
index 540a612..f92a7f4 100644 (file)
@@ -878,7 +878,7 @@ static int start_transient_service(
                 (void) sd_event_add_signal(event, NULL, SIGTERM, NULL, NULL);
 
                 if (!arg_quiet)
-                        log_info("Running as unit %s\nPress ^] three times within 1s to disconnect TTY.", service);
+                        log_info("Running as unit: %s\nPress ^] three times within 1s to disconnect TTY.", service);
 
                 r = pty_forward_new(event, master, PTY_FORWARD_IGNORE_INITIAL_VHANGUP, &forward);
                 if (r < 0)
@@ -896,7 +896,7 @@ static int start_transient_service(
                         fputc('\n', stdout);
 
         } else if (!arg_quiet)
-                log_info("Running as unit %s", service);
+                log_info("Running as unit: %s", service);
 
         return 0;
 }
@@ -1038,7 +1038,7 @@ static int start_transient_scope(
                 return r;
 
         if (!arg_quiet)
-                log_info("Running scope as unit %s", scope);
+                log_info("Running scope as unit: %s", scope);
 
         execvpe(argv[0], argv, env);
 
@@ -1189,9 +1189,9 @@ static int start_transient_timer(
         if (r < 0)
                 return r;
 
-        log_info("Running timer as unit %s", timer);
+        log_info("Running timer as unit: %s", timer);
         if (argv[0])
-                log_info("Will run service as unit %s", service);
+                log_info("Will run service as unit: %s", service);
 
         return 0;
 }