Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^14: Backdating strict

by choroba (Cardinal)
on Nov 21, 2020 at 01:17 UTC ( [id://11123954]=note: print w/replies, xml ) Need Help??


in reply to Re^13: Backdating strict
in thread Backdating strict

emacsclient needs no setting up. Just add
(server-start)

to your startup file and open a file using emacsclient instead of emacs (I defined a shell function ec for that, and evan made it start emacs if it's not already running).

The only difference now is you close the files with C-x # instead of C-x k, but I wrote the following lisp function

(defun server-edit-or-close (buf) "Close the buffer regardless of whether it's a server file or not." (interactive "bKill/finish buffer: ") (if server-buffer-clients (progn (switch-to-buffer buf) (server-edit)) (kill-buffer)))

and bound it to

(global-set-key "\C-xk" 'server-edit-or-close)

and I can close a file using the standard way no matter how it was opened.

map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11123954]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (4)
As of 2024-04-25 12:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found