[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: find the file name of the running function programatically
From: |
Chat |
Subject: |
Re: find the file name of the running function programatically |
Date: |
Thu, 28 Aug 2008 00:54:04 -0700 |
User-agent: |
Emacs Gnus |
Xah <xahlee@gmail.com> writes:
> how to find out the file name of the running function
> programmatically?
>
> for example, i have:
>
> (defun command-frequency-write-file (file-name)
> (with-temp-file file-name
> (insert (command-frequency)))
> (with-temp-message (format "Wrote %s" file-name)))
>
> i want to change this function so that it doesn't require any arg.
> The file name will just be in the same dir but with a “.txt” suffix.
>
> Thanks.
>
> Xah
> ∑ http://xahlee.org/
>
> ☄
Doesn't look like there is a simple function that will work in all versions.
However, given that not all libraries reside on writable file systens, doesn't
it make sense to store it somewhere under HOME?
Chat