help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

`batch-byte-compile' for directories?


From: Philipp Stephani
Subject: `batch-byte-compile' for directories?
Date: Fri, 19 Jun 2015 20:19:04 +0200

Hi,

the function `batch-byte-compile' supports directories.  The code for
this is:

          (let (source dest)
            (dolist (file (directory-files (car command-line-args-left)))
              (if (and (string-match emacs-lisp-file-regexp file)
                       (not (auto-save-file-name-p file))
                       (setq source
                             (expand-file-name file
                                               (car command-line-args-left)))
                       (setq dest (byte-compile-dest-file source))
                       (file-exists-p dest)
                       (file-newer-than-file-p source dest))
                  (if (null (batch-byte-compile-file source))
                      (setq error t)))))

What I find weird is the condition that the destination file has to
exist for the compilation to be performed.  I would expect logic similar
to the explicit file case (don't check destination file by default, and
if NOFORCE is set check for either nonexistent or old destination
file).  Is the current behavior intended?

Thanks,
Philipp

-- 
Google Germany GmbH
Dienerstraße 12
80331 München

Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Graham Law, Christine Elizabeth Flores

Diese E-Mail ist vertraulich.  Wenn Sie nicht der richtige Adressat sind,
leiten Sie diese bitte nicht weiter, informieren Sie den Absender und löschen
Sie die E-Mail und alle Anhänge.  Vielen Dank.
       
This e-mail is confidential.  If you are not the right addressee please do not
forward it, please inform the sender, and please erase this e-mail including
any attachments.  Thanks.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]