From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thierry Volpiatto Newsgroups: gmane.emacs.devel Subject: Re: how having the basename of a file or directory Date: Mon, 31 Jan 2011 12:03:14 +0100 Message-ID: <877hdl5o99.fsf@gmail.com> References: <8739o9ilfs.fsf@gmail.com> <877hdl4grd.fsf@uwakimon.sk.tsukuba.ac.jp> <87y661h2ju.fsf@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1296472321 25470 80.91.229.12 (31 Jan 2011 11:12:01 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 31 Jan 2011 11:12:01 +0000 (UTC) Cc: "Stephen J. Turnbull" , emacs-devel@gnu.org To: Andreas Schwab Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jan 31 12:11:56 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pjrfm-0007Ia-9s for ged-emacs-devel@m.gmane.org; Mon, 31 Jan 2011 12:11:55 +0100 Original-Received: from localhost ([127.0.0.1]:47568 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PjrXi-0003oz-Di for ged-emacs-devel@m.gmane.org; Mon, 31 Jan 2011 06:03:34 -0500 Original-Received: from [140.186.70.92] (port=48276 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PjrXU-0003ms-6t for emacs-devel@gnu.org; Mon, 31 Jan 2011 06:03:21 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PjrXS-0004kC-Ui for emacs-devel@gnu.org; Mon, 31 Jan 2011 06:03:20 -0500 Original-Received: from mail-ww0-f41.google.com ([74.125.82.41]:52736) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PjrXS-0004k6-Mn for emacs-devel@gnu.org; Mon, 31 Jan 2011 06:03:18 -0500 Original-Received: by wwi18 with SMTP id 18so3368082wwi.0 for ; Mon, 31 Jan 2011 03:03:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-type; bh=/0p8vsQRGxCwsUWVMuxndQI+OGBRQOP+t6VRyYEKySg=; b=av6JVrsb5vHvaucCi7a/VQI6voQcL1sgX342hNr1tkrs0EA6KHPC7h6EYk6fv2/W30 r+82vuFMuOAtY7T/sF9ns0swK5c9ltgXfcS6QPpGVW5En7mOWtsFpz/3xWXruBsFDjvK OcFvQ3RJ74cDUff7XUz+QGRbQxfaXkDh6L5QU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; b=x89/ZNsUXlOW0f9MoG4hT84fGPEDvvE2DVmVIE2y88Z97apc32Ijp7oZ0kA/bcqlm6 zggyqHMnp+LXtlubpZZgXiKaIB9IoNKE6C61aeVBf34DpbApvnLYIkMrB1HNOsMi3VKv 5qCiu7x7CRXLuSE8GtwEawtkFyXpjz172PFsY= Original-Received: by 10.227.153.1 with SMTP id i1mr5963765wbw.97.1296471797591; Mon, 31 Jan 2011 03:03:17 -0800 (PST) Original-Received: from thierry-MM061 (63.211.85-79.rev.gaoland.net [79.85.211.63]) by mx.google.com with ESMTPS id j49sm10706094wer.14.2011.01.31.03.03.15 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 31 Jan 2011 03:03:16 -0800 (PST) In-Reply-To: (Andreas Schwab's message of "Mon, 31 Jan 2011 11:28:37 +0100") User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.2.92 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 74.125.82.41 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:135291 Archived-At: Andreas Schwab writes: > Thierry Volpiatto writes: > >> (file-name-nondirectory "path/to/a/directory") >> should return ==> directory > > It does. Not really. It does if PATH doesn't end with "/" otherwise no, it's why (file-name-nondirectory (directory-file-name PATH)) is needed as Stephen said. You see, it's confusing ;-) -- A+ Thierry Get my Gnupg key: gpg --keyserver pgp.mit.edu --recv-keys 59F29997