Chong Yidong
0191e222e3
Add --parent-id argument to emacsclient.
...
* lib-src/emacsclient.c (longopts, decode_options, print_help_and_exit):
New arg `-parent-id'.
(main): Send parent-id to Emacs.
* lisp/server.el (server-process-filter): Receive parent-id argument
from emacsclient.
(server-create-window-system-frame): New arg. Pass parent-id as
frame parameter.
2010-05-29 19:50:47 -04:00
Chong Yidong
f1a5d776c4
Change delete-by-moving-to-trash so Lisp calls explicitly request trashing.
...
* src/fileio.c (Fdelete_file): Change meaning of optional arg to mean
whether to trash.
(internal_delete_file, Frename_file): Callers changed.
(delete_by_moving_to_trash): Doc fix.
(Fdelete_directory_internal): Don't move to trash.
* src/callproc.c (delete_temp_file):
* src/buffer.c (Fkill_buffer): Callers changed.
* src/lisp.h: Update prototype.
* lisp/diff.el (diff-sentinel):
* lisp/epg.el (epg--make-temp-file, epg-decrypt-string)
(epg-verify-string, epg-sign-string, epg-encrypt-string):
* lisp/jka-compr.el (jka-compr-partial-uncompress)
(jka-compr-call-process, jka-compr-write-region):
* lisp/server.el (server-sentinel): Remove optional arg from
delete-file, reverting 2010-05-03 change.
* lisp/dired.el (dired-delete-file): New arg TRASH.
(dired-internal-do-deletions): New arg TRASH. Use progress
reporter.
(dired-do-flagged-delete, dired-do-delete): Use trash.
* lisp/files.el (delete-directory): New arg TRASH.
* lisp/speedbar.el (speedbar-item-delete): Allow trashing.
* lisp/net/ange-ftp.el (ange-ftp-del-tmp-name, ange-ftp-delete-file)
(ange-ftp-rename-remote-to-remote)
(ange-ftp-rename-local-to-remote)
(ange-ftp-rename-remote-to-local, ange-ftp-load)
(ange-ftp-compress, ange-ftp-uncompress): Remove optional arg from
`delete-file'.
(ange-ftp-delete-directory): Add optional arg to `delete-file', to
allow trashing.
* lisp/net/tramp-compat.el (tramp-compat-delete-file): Rewrite to
handle new TRASH arg of `delete-file'.
* lisp/net/tramp-fish.el (tramp-fish-handle-delete-directory)
(tramp-fish-handle-delete-file)
(tramp-fish-handle-make-symbolic-link)
(tramp-fish-handle-process-file): Use null TRASH arg in
`tramp-compat-delete-file' call.
* lisp/net/tramp-ftp.el (tramp-ftp-file-name-handler): Use null TRASH
arg in `tramp-compat-delete-file' call.
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-delete-file): Rename arg.
(tramp-gvfs-handle-write-region): Use null TRASH arg in
`tramp-compat-delete-file' call.
* lisp/net/tramp-imap.el (tramp-imap-handle-delete-file): Rename arg.
(tramp-imap-do-copy-or-rename-file): Use null TRASH arg in
`tramp-compat-delete-file' call.
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-file)
(tramp-smb-handle-file-local-copy, tramp-smb-handle-rename-file)
(tramp-smb-handle-write-region): Use null TRASH arg in
tramp-compat-delete-file call.
(tramp-smb-handle-delete-directory): Use tramp-compat-delete-file.
(tramp-smb-handle-delete-file): Rename arg.
* lisp/net/tramp.el (tramp-handle-delete-file): Change FORCE arg to TRASH.
(tramp-handle-make-symbolic-link, tramp-handle-load)
(tramp-do-copy-or-rename-file-via-buffer)
(tramp-do-copy-or-rename-file-directly)
(tramp-do-copy-or-rename-file-out-of-band)
(tramp-handle-process-file, tramp-handle-call-process-region)
(tramp-handle-shell-command, tramp-handle-file-local-copy)
(tramp-handle-insert-file-contents, tramp-handle-write-region)
(tramp-delete-temp-file-function): Use null TRASH arg in
tramp-compat-delete-file call.
2010-05-27 19:30:11 -04:00
Chong Yidong
53967e09ad
Add optional arg to delete-file to force deletion (Bug#6070).
...
* eval.c (internal_condition_case_n): Rename from
internal_condition_case_2.
(internal_condition_case_2): New function.
* xdisp.c (safe_call): Use internal_condition_case_n.
* fileio.c (Fdelete_file, internal_delete_file): New arg FORCE.
(internal_delete_file, Frename_file): Callers changed.
* buffer.c (Fkill_buffer):
* callproc.c (delete_temp_file): Callers changed (Bug#6070).
* lisp.h: Update prototypes.
* diff.el (diff-sentinel):
* epg.el (epg--make-temp-file, epg-decrypt-string)
(epg-verify-string, epg-sign-string, epg-encrypt-string):
* jka-compr.el (jka-compr-partial-uncompress)
(jka-compr-call-process, jka-compr-write-region, jka-compr-load):
* server.el (server-sentinel): Use delete-file's new FORCE arg
(Bug#6070).
2010-05-03 11:01:21 -04:00
Chong Yidong
84716442f0
Avoid using trash for certain temp files (Bug#6070).
...
* server.el (server-sentinel, server-start, server-force-delete):
* jka-compr.el (jka-compr-partial-uncompress)
(jka-compr-call-process, jka-compr-write-region, jka-compr-load):
* epg.el (epg--make-temp-file, epg-decrypt-string)
(epg-encrypt-string, epg-verify-string, epg-sign-string):
* diff.el (diff-sentinel): Bind delete-by-moving-to-trash to nil
before deleting (Bug#6070).
2010-04-30 22:19:40 -04:00
Glenn Morris
114f9c9679
Add 2010 to copyright years.
2010-01-13 00:35:10 -08:00
Juanma Barranquero
3e70541aed
This fixes bug#4197 (merged to bug#865, though not identical).
...
* server.el (server-auth-dir): Add docstring note about FAT32.
(server-ensure-safe-dir): Accept FAT32 directories as "safe",
but warn against using them.
2009-09-19 14:56:04 +00:00
Juanma Barranquero
d75541671f
* server.el (server-ensure-safe-dir): Pass 'integer
...
to `file-attributes', as suggested.
2009-09-18 16:55:21 +00:00
Glenn Morris
597e2240ab
Use default-value rather than default-enable-multibyte-characters.
2009-09-03 06:54:57 +00:00
Glenn Morris
e6ce8c4239
Use forward-line rather than goto-line.
2009-08-22 19:29:18 +00:00
Chong Yidong
2d25aa5a90
* server.el (server-buffer-done): Prevent kill-buffer from
...
prompting by clearing the buffer modification flag (Bug#3696).
2009-06-29 03:25:10 +00:00
Stefan Monnier
ba528748a1
* server.el (server-process-filter): Use expand-file-name rather than
...
command-line-normalize-file-name so as to use the `dir' when provided.
* emacsclient.c (main): Always pass cwd via "-dir". Pass the file
names without prepending cwd to them, so Emacs uses its customary
rules to determine how to interpret the file name.
2009-03-10 14:08:52 +00:00
Miles Bader
a20878b6d8
Rename system-process-attributes' to
process-attributes'
...
Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1553
2009-02-23 05:06:36 +00:00
Chong Yidong
c31ee0038d
(server-start): Make the warning more verbose (Bug#2395).
2009-02-20 02:16:25 +00:00
Juanma Barranquero
abab01f2e8
* server.el (server-with-environment): Don't fail for negative entries in ENV.
2009-02-11 09:22:59 +00:00
Chong Yidong
035426050b
Add comment.
2009-02-07 21:59:35 +00:00
Stefan Monnier
7197f5de6f
(server-execute): Enable quit.
2009-02-07 16:24:36 +00:00
Chong Yidong
77c4d02405
(server-name): Make it a defcustom.
2009-01-23 04:52:40 +00:00
Dan Nicolaescu
f79b43b27b
* frame.el (make-frame-on-tty): Remove function, inline contents
...
in the only user ...
* server.el (server-create-tty-frame): ... here.
* frames.texi (Multiple Displays): Remove documentation for
removed function make-frame-on-tty.
2009-01-22 06:58:10 +00:00
Chong Yidong
97e121ccb0
(server-start): Allow server to shut down when no frames are available
...
in daemon-mode.
2009-01-21 20:33:17 +00:00
Chong Yidong
ac088d51a0
(server-save-buffers-kill-terminal): Args changed. Handle nowait
...
client frames.
2009-01-11 16:45:36 +00:00
Chong Yidong
1ea67c3edb
Delete incorrect comment.
2009-01-11 16:15:38 +00:00
Chong Yidong
052056a969
Revert previous change (commit mistake).
2009-01-10 13:07:04 +00:00
Chong Yidong
6c1ec5a050
* gs.el: File removed.
2009-01-10 13:04:37 +00:00
Glenn Morris
ae940284fa
Add 2009 to copyright years.
2009-01-05 03:18:22 +00:00
Andreas Schwab
d9569a55d8
(server-running-p): Remove interactive spec. Fix
...
regexp.
2008-12-30 11:28:14 +00:00
Juanma Barranquero
35f372cadf
* server.el (server-start): If unable to start the server,
...
display a warning instead of raising an error.
* startup.el (server-process): Add defvar.
(command-line): If the daemon is unable to start the server,
display a message and exit Emacs.
2008-12-16 21:23:03 +00:00
Juanma Barranquero
c63a334eb0
* server.el (server-sentinel): Uncomment code to delete connection file.
...
(server-start): Save the connection file in the server property list.
Delete it only when we are reasonably convinced that it is not owned by
a running server.
(server-force-delete): New command to force-delete the connection file,
and stop the server if it is running.
(server-running-p): Return t also for local TCP servers when we find a
process with a matching PID, and :other for undecided cases.
2008-12-12 00:33:30 +00:00
Juanma Barranquero
a77ad24064
* server.el (server-temp-file-p): Use `string-match-p'.
...
(server-socket-dir): Set to nil if local sockets are unsupported.
(server-start): Don't try to delete local socket if unsupported.
(server-kill-new-buffers): Reflow docstring.
(server-delete-client, server-handle-delete-frame)
(server-save-buffers-kill-terminal): Doc fixes.
(server-send-string): Fix typo in docstring.
2008-11-18 16:27:06 +00:00
Juanma Barranquero
909049cbf2
* server.el (server-process-filter): Fix typos and reflow docstring.
2008-11-11 10:51:35 +00:00
Chong Yidong
d9bf544c71
(server-process-filter): Only default to emacsclient's terminal in
...
daemon mode.
2008-11-05 21:16:17 +00:00
Chong Yidong
650d0dbc02
(server-process-filter): Don't call server-create-tty-frame when no
...
tty name is specified.
2008-11-04 18:42:04 +00:00
Chong Yidong
cd9c54eb5f
(server-process-filter): In daemon mode, default to emacsclient's tty
...
if not opening a new frame and only the terminal-frame is available.
2008-10-30 15:50:01 +00:00
Juanma Barranquero
f77b11a051
* server.el, emacsclient.c: Use TMPDIR (default /tmp) instead of hardcoded /tmp.
2008-10-29 10:42:31 +00:00
Juanma Barranquero
d6c180c46b
New function `locate-user-emacs-file'.
...
* subr.el (locate-user-emacs-file): New function.
(user-emacs-directory): Mention it in docstring.
* completion.el (save-completions-file-name):
* filesets.el (filesets-menu-cache-file):
* image-dired.el (image-dired-dir, image-dired-db-file)
(image-dired-temp-image-file, image-dired-gallery-dir)
(image-dired-temp-rotate-image-file):
* savehist.el (savehist-file):
* server.el (server-auth-dir):
* startup.el (auto-save-list-file-prefix):
* thumbs.el (thumbs-thumbsdir):
* tutorial.el (tutorial--saved-dir):
* play/gamegrid.el (gamegrid-user-score-file-directory): Use it.
* url.el (url-configuration-directory): Use `locate-user-emacs-file'.
* NEWS: New function `locate-user-emacs-file'.
2008-10-24 09:39:27 +00:00
Chong Yidong
737e5c834b
(server-buffer-done): Avoid changing the buffer when deleting the
...
client's frame (bug#640).
2008-09-24 20:12:02 +00:00
Chong Yidong
ee0aed46c6
(server-switch-buffer): New arg.
...
(server-execute): If reusing an existing window, set file position
if required.
2008-09-06 17:17:05 +00:00
Glenn Morris
eb3fa2cfcf
Switch to recommended form of GPLv3 permissions notice.
2008-05-06 08:06:51 +00:00
Stefan Monnier
1b0a6c68e6
(server-start): Also don't get confused by CRs since we
...
don't quote them.
2008-04-23 15:37:07 +00:00
Andreas Schwab
a7ce6c7f5d
(server-switch-buffer): Also consider clients in the
...
selected frame.
2008-04-20 08:32:11 +00:00
Stefan Monnier
6afdf6e69a
Undo part of the multi-tty change, which is only needed if server.el is
...
preloaded, and broke server-running-p.
(server-socket-dir): Initialize in the defvar, as before.
(server-start): Remove initialization of server-socket-dir.
2008-04-05 17:55:00 +00:00
Juanma Barranquero
f03ea9d918
(server-log-time-function): Doc fix.
...
(server-buffer): Fix typo in docstring.
2008-01-27 22:47:58 +00:00
Dan Nicolaescu
475b590773
* server.el (server-process-filter): Check for non-nil before calling
...
file-directory-p.
2008-01-27 15:37:26 +00:00
Stefan Monnier
28cbade418
(server-buffer): New const.
...
(server-log): New var.
(server-log): Use them.
(server-process-filter): (Try to) run the continuation in the same cwd
as the client's.
2008-01-26 21:54:44 +00:00
Juanma Barranquero
38b9f0f370
(server-process-filter): Don't force the authentication
...
string to be followed by "\n".
2008-01-25 15:43:05 +00:00
Juanma Barranquero
88fd26a1c7
(server-log-time-function): New function.
...
(server-log): Use it.
2008-01-21 12:06:59 +00:00
Stefan Monnier
656d4706ab
(server-process-filter): Replace lineno and columnnno
...
which defaulted to 1&0 with filepos which defaults to nil.
(server-goto-line-column): Don't move if filepos is nil.
(server-visit-files): Slight restructure to consolidate two calls to
server-goto-line-column into just one.
2008-01-16 16:21:08 +00:00
Stefan Monnier
f86228e36c
(server-create-window-system-frame): Remove workaround for
...
a bug that has been fixed.
2008-01-03 21:56:36 +00:00
Stefan Monnier
c61a444841
(server-save-buffers-kill-terminal): Check the `proc' is indeed a process.
2007-12-23 22:46:07 +00:00
Stefan Monnier
ff91dc79ef
(server-select-display): Fix important typo.
...
(server-process-filter): Turn a "" display into nil.
2007-12-10 03:51:25 +00:00
David Kastrup
bfb74e75a4
* server.el (server-process-filter): Use `command-line-args-left'
2007-11-23 23:59:19 +00:00