From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: david@adboyd.com (J. David Boyd) Newsgroups: gmane.emacs.help Subject: Re: Customising .init.el for root user Date: Fri, 21 Jun 2013 10:55:09 -0400 Message-ID: References: <871u7woijw.fsf@gmx.co.uk> <874ncra9fp@ch.ristopher.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1371826550 2133 80.91.229.3 (21 Jun 2013 14:55:50 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 21 Jun 2013 14:55:50 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jun 21 16:55:49 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Uq2kY-0004Hg-Aj for geh-help-gnu-emacs@m.gmane.org; Fri, 21 Jun 2013 16:55:42 +0200 Original-Received: from localhost ([::1]:35900 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uq2kY-0007hL-28 for geh-help-gnu-emacs@m.gmane.org; Fri, 21 Jun 2013 10:55:42 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59463) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uq2kM-0007f3-FS for help-gnu-emacs@gnu.org; Fri, 21 Jun 2013 10:55:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uq2kJ-0003gG-Pm for help-gnu-emacs@gnu.org; Fri, 21 Jun 2013 10:55:30 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:42302) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uq2kJ-0003g9-J3 for help-gnu-emacs@gnu.org; Fri, 21 Jun 2013 10:55:27 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Uq2kD-0003sU-91 for help-gnu-emacs@gnu.org; Fri, 21 Jun 2013 16:55:21 +0200 Original-Received: from 169.15.137.27 ([169.15.137.27]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 21 Jun 2013 16:55:21 +0200 Original-Received: from david by 169.15.137.27 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 21 Jun 2013 16:55:21 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 27 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 169.15.137.27 User-Agent: Gnus/5.1299999999999999 (Gnus v5.13) Emacs/24.3 (cygwin) Cancel-Lock: sha1:bx2fwITT/yE+PtoJJLWfpnm13nA= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:91635 Archived-At: Christopher Schmidt writes: > david@adboyd.com (J. David Boyd) writes: >> (setq whoami-string >> (substring >> (shell-command-to-string "whoami") >> 0 -1)) >> >> >> >> Then you could do >> >> (when (string= (whoami-string) "root") >> ..run some customisations... >> ) > > (eq (user-uid) 0) > > Christopher Then root is always user id 0? Never knew that, nor took the time to check ever. Thanks for the info... Dave