Path: utzoo!attcan!utgpu!watmath!iuvax!purdue!haven!louie From: louie@haven.umd.edu (Louis Mamakos) Newsgroups: comp.emacs Subject: Re: Getting hostname on status line. Message-ID: <1989Oct23.140331.17293@haven.umd.edu> Date: 23 Oct 89 14:03:31 GMT References: <1612@fredonia.UUCP> <8910032315.AA10699@cunixc.cc.columbia.edu> <688@corona.pb> Reply-To: louie@sayshell.umd.edu (Louis A. Mamakos) Organization: /etc/organization Lines: 27 Here's what I do in my .emacs go get the hostname in the status line: (setq short-hostname (substring (system-name) 0 (string-match "\\." (system-name)))) (setq-default mode-line-format '("--%1*%1*-" mode-line-buffer-identification " " global-mode-string " %[(" mode-name minor-mode-alist "%n" mode-line-process ")%]----" (-3 . "%p") "----<" short-hostname ">-%-") ) which seem wo work just fine. short-hostname is the name of the host with any domain suffix stripped off. My mode line right now looks like this: --**-Emacs: .article (Text)----All--------------------- where my hostname is 'sayshell.umd.edu'. louie