File: title.c

package info (click to toggle)
splitvt 1.6.5-0potato1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 332 kB
  • ctags: 399
  • sloc: ansic: 4,684; sh: 78; makefile: 55; perl: 15
file content (13 lines) | stat: -rw-r--r-- 230 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* Set the titlebar on an xterm */

#include <stdio.h>

main(int argc, char *argv[])
{
	if ( argc != 2 ) {
		fprintf(stderr, "%s title-text\n", argv[0]);
		exit(1);
	}
	printf("\033]0;%s\07", argv[1]); fflush(stdout);
	exit(0);
}