[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/crdt 9f83928758 32/44: Merge branch 'master' into devel
From: |
ELPA Syncer |
Subject: |
[elpa] externals/crdt 9f83928758 32/44: Merge branch 'master' into development |
Date: |
Sat, 2 Jul 2022 22:57:34 -0400 (EDT) |
branch: externals/crdt
commit 9f839287583fe8422a6bf113f6de41a63ecaa00a
Merge: 89e3a2699d 81b55a27b8
Author: Qiantan Hong <qhong@alum.mit.edu>
Commit: Qiantan Hong <qhong@alum.mit.edu>
Merge branch 'master' into development
---
README.org | 93 +++++++++++++++++++++++++++++++++-----------------------------
crdt.el | 19 +++++++------
2 files changed, 61 insertions(+), 51 deletions(-)
diff --git a/README.org b/README.org
index 0a3d68100d..639e4a83ee 100644
--- a/README.org
+++ b/README.org
@@ -16,6 +16,13 @@ Highlights:
~crdt.el~ is now on GNU ELPA! Just =M-x package-install crdt=.
+*Caution!!!* Please make sure that you and your peers are on the same
~crdt.el~ version!
+It turns out to be one of the most common causes of ~crdt.el~ not working.
+Because currently the network protocol is not stablized, behavior when using
mismatched versions is unexpectable.
+- Strictly speaking, it should works when =crdt-protocol-version= are defined
and the same on all peers.
+ But why not save some hassle and keep everyone on the latest version.
+- To upgrade, just =M-x package-reinstall crdt=, then preferably restart Emacs.
+
** Start a shared session
A shared session is a place that can contains multiple buffers (or files),
@@ -33,49 +40,6 @@ optional password and your display name (default to your
current =(user-full-nam
** Join a session
=M-x crdt-connect=, then enter address, port, and your display name.
-
-** What if we don't have a public IP?
-
-There're various workaround.
-
-- You can use [[https://gitlab.com/gjedeer/tuntox][tuntox]] to proxy your
connection over the [[https://tox.chat][Tox]] protocol.
- =crdt.el= has experimental built-in integration for =tuntox=.
- To enable it, you need to install =tuntox=,
- set up the custom variable =crdt-tuntox-executable= accordingly (the path to
your =tuntox= binary),
- and set the custom variable =crdt-use-tuntox=.
- Setting it to =t= make =crdt.el= always create =tuntox= proxy for new server
sessions,
- and setting it to ='confirm= make =crdt.el= ask you every time when creating
new sessions.
- After starting a session with =tuntox= proxy,
- you can =M-x crdt-copy-url= to copy a URL recognizable by =M-x crdt-connect=
and share it to your friends.
- Be aware that according to my experience, =tuntox= takes significant time to
establish a connection (sometimes up to half a minute),
- however it gets much faster after the connection is established.
-
-- You can use Teredo to get a public routable IPv6 address.
- One free software implementation is Miredo. Get it from your
- favorite package manager or from [[https://www.remlab.net/miredo/][their
website]].
- A typical usage is (run as root)
- #+BEGIN_SRC
-# /usr/local/sbin/miredo
-# ifconfig teredo
- #+END_SRC
- The =ifconfig= command should print the information of your IPv6 address.
- Now your traffic go through IPv6, and once you start a =crdt.el= session,
- your friends should be able to join using the IPv6 address.
- For more information, see the user guide on the Miredo website.
-
-- You can use SSH port forwarding if you have a VPS with public IP.
- Example usage:
- #+BEGIN_SRC
-$ ssh -R EXAMPLE.COM:6530:127.0.0.1:6530 EXAMPLE.COM
- #+END_SRC
- This make your =crdt.el= session on local port =6530= accessible from
- =EXAMPLE.COM:6530=.
-
- Note that you need to set the following =/etc/ssh/sshd_config= option on
- your VPS
- #+BEGIN_SRC
-GatewayPorts yes
- #+END_SRC
** List active users
@@ -125,3 +89,46 @@ Just go ahead and share you comint REPL buffer! Tested:
~shell~ and ~cmuscheme~.
By default, when sharing a comint buffer, ~crdt.el~ temporarily reset input
history (as in =M-n= =M-p=)
so others don't spy into your =.bash_history= and alike.
You can customize this behavior using variable
=crdt-comint-share-input-history=.
+
+** What if we don't have a public IP?
+
+There're various workaround.
+
+- You can use [[https://gitlab.com/gjedeer/tuntox][tuntox]] to proxy your
connection over the [[https://tox.chat][Tox]] protocol.
+ =crdt.el= has experimental built-in integration for =tuntox=.
+ To enable it, you need to install =tuntox=,
+ set up the custom variable =crdt-tuntox-executable= accordingly (the path to
your =tuntox= binary),
+ and set the custom variable =crdt-use-tuntox=.
+ Setting it to =t= make =crdt.el= always create =tuntox= proxy for new server
sessions,
+ and setting it to ='confirm= make =crdt.el= ask you every time when creating
new sessions.
+ After starting a session with =tuntox= proxy,
+ you can =M-x crdt-copy-url= to copy a URL recognizable by =M-x crdt-connect=
and share it to your friends.
+ Be aware that according to my experience, =tuntox= takes significant time to
establish a connection (sometimes up to half a minute),
+ however it gets much faster after the connection is established.
+
+- You can use Teredo to get a public routable IPv6 address.
+ One free software implementation is Miredo. Get it from your
+ favorite package manager or from [[https://www.remlab.net/miredo/][their
website]].
+ A typical usage is (run as root)
+ #+BEGIN_SRC
+# /usr/local/sbin/miredo
+# ifconfig teredo
+ #+END_SRC
+ The =ifconfig= command should print the information of your IPv6 address.
+ Now your traffic go through IPv6, and once you start a =crdt.el= session,
+ your friends should be able to join using the IPv6 address.
+ For more information, see the user guide on the Miredo website.
+
+- You can use SSH port forwarding if you have a VPS with public IP.
+ Example usage:
+ #+BEGIN_SRC
+$ ssh -R EXAMPLE.COM:6530:127.0.0.1:6530 EXAMPLE.COM
+ #+END_SRC
+ This make your =crdt.el= session on local port =6530= accessible from
+ =EXAMPLE.COM:6530=.
+
+ Note that you need to set the following =/etc/ssh/sshd_config= option on
+ your VPS
+ #+BEGIN_SRC
+GatewayPorts yes
+ #+END_SRC
diff --git a/crdt.el b/crdt.el
index 9cc3844c91..2adc2485a3 100644
--- a/crdt.el
+++ b/crdt.el
@@ -3037,14 +3037,17 @@ The result DIFF can be used in (CRDT--NAPPLY-DIFF OLD
DIFF) to reproduce NEW."
(cl-defun crdt--send-process-mark-maybe (&optional (lazy t))
(let ((buffer-process (get-buffer-process (current-buffer))))
(when buffer-process
- (let* ((mark-pos (marker-position (process-mark buffer-process)))
- (current-id (crdt--get-id mark-pos)))
- (unless (and lazy (string-equal crdt--last-process-mark-id current-id))
- (setq crdt--last-process-mark-id current-id)
- (crdt--broadcast-maybe
- (crdt--format-message
- `(process-mark ,crdt--buffer-network-name
- ,current-id ,mark-pos))))))))
+ (let* ((mark (process-mark buffer-process)))
+ (when mark
+ (let* ((mark-pos (marker-position mark)))
+ (when mark-pos
+ (let* ((current-id (crdt--get-id mark-pos)))
+ (unless (and lazy (string-equal crdt--last-process-mark-id
current-id))
+ (setq crdt--last-process-mark-id current-id)
+ (crdt--broadcast-maybe
+ (crdt--format-message
+ `(process-mark ,crdt--buffer-network-name
+ ,current-id ,mark-pos))))))))))))
(defun crdt--process-status-advice (orig-func process)
(if (crdt--pseudo-process-p process)
- [elpa] externals/crdt 2c68377c15 01/44: Merge branch 'master' into development, (continued)
- [elpa] externals/crdt 2c68377c15 01/44: Merge branch 'master' into development, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 102498e84f 12/44: remove tramp for now, keep it simple, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 357f4b7174 18/44: more sensible version message, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt b222966674 19/44: fix DEL key in forms mode, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 5e67684793 20/44: fix bug of hanging data buffer when CRDT--READ-SETTINGS errors, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt e06e6e7236 21/44: add history support for CRDT-READ-SETTINGS, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt fae016ba25 08/44: Preliminary url support, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 28c5f6bd0e 27/44: Also `crdt--refresh-users-maybe' when `crdt-stop-follow', ELPA Syncer, 2022/07/02
- [elpa] externals/crdt f81f5297fa 28/44: Improve naming for user and buffer list, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 0743dd15f0 29/44: change `crdt--session-name' to `crdt--session-urlstr', ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 9f83928758 32/44: Merge branch 'master' into development,
ELPA Syncer <=
- [elpa] externals/crdt 7548a9420e 33/44: :name->:urlstr, and fix TLS downgrade, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 01551d66c9 34/44: Fix default theme bug and other bugs., ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 949f4a1afd 37/44: reflect key binding addition in README.org, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 780478a090 39/44: Fix crdt--cycle-user bug with different buffer/window, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt df8954b9c3 40/44: feat: Option to put tuntox password in copied URL, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 72e2b8be12 42/44: Merge branch 'master' into development, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 3883736730 17/44: many changes, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt e2b6c9ebf6 22/44: get sharing buffer from clients working, ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 932566653e 23/44: TLS support by stunnel., ELPA Syncer, 2022/07/02
- [elpa] externals/crdt 282c48c47c 44/44: Revise README, ELPA Syncer, 2022/07/02