Commit graph

554 commits

Author SHA1 Message Date
Joey Hess
e10137b4da upper-case first char of buddy name 2012-11-12 13:27:30 -04:00
Joey Hess
8fd78f45a2 fix build without XMPP
not sure if I'll keep bothering with this option
2012-11-12 01:48:15 -04:00
Joey Hess
8b22bd8831 add a yes/no confirm for xmpp pairing requests 2012-11-11 22:29:16 -04:00
Joey Hess
522e228aef auto-accept pair requests from JIDs already paired with 2012-11-11 18:16:11 -04:00
Joey Hess
b91f07fe83 split up xmpp and local pairing UIs 2012-11-11 17:41:56 -04:00
Joey Hess
5e44ab177c don't try to transfer data to/from XMPP remotes
Partition syncRemotes into ones needing git sync (ie, non-special remotes),
and ones needing data sync (ie, non-XMPP remotes).
2012-11-11 16:23:16 -04:00
Joey Hess
217eeede43 allow both one push and one receive-pack to run at the same time
Noticed that when pairing, sometimes both sides start to push, and the other
side sends a PushRequest, and the two deadlock, neither doing anything.
(Timeout eventually breaks this.) So, let both run at the same time.
2012-11-11 15:42:03 -04:00
Joey Hess
b44e8bb4a5 add 120 second timeout when waiting for XMPP packets 2012-11-11 13:38:28 -04:00
Joey Hess
6a0756d2fb use trustExclude 2012-11-11 00:26:29 -04:00
Joey Hess
3f8ce7a0c5 reword alert 2012-11-10 20:52:46 -04:00
Joey Hess
f3bbe075f2 fix creation of creds directory for xmpp 2012-11-10 20:48:45 -04:00
Joey Hess
b160856297 end of xmpp pairing page encourages adding a shared cloud repository 2012-11-10 20:38:52 -04:00
Joey Hess
75048b43e2 split repository comfiguration page into several widgets 2012-11-10 17:08:43 -04:00
Joey Hess
fd22734392 show when a buddy is already paired 2012-11-10 16:36:21 -04:00
Joey Hess
41085cdc8c set negative XMPP presence priority
This should help prevent git-annex clients receiving messages that
were intended for normal clients they're sharing the account with.

Changed XMPP protocol use to always send chat messages directed at the
specific client, as the negative priority blocks less directed messages.
2012-11-10 15:33:12 -04:00
Joey Hess
ec186d6369 avoid sending xmpp push notifications when not pushing to any remotes 2012-11-10 14:52:25 -04:00
Joey Hess
957e742dfc full-on git-annex assistant syncing now works over XMPP!
I decided to use the fallback push mode from the beginning for XMPP, since
while it uses some ugly branches, it avoids the possibility of a normal
push failing, and needing to pull and re-push. Due to the overhead of XMPP,
and the difficulty of building such a chain of actions due to the async
implementation, this seemed reasonable.

It seems to work great!
2012-11-10 14:38:50 -04:00
Joey Hess
7a20b3f1d5 more refactoring 2012-11-10 14:01:24 -04:00
Joey Hess
0cf4c3ba9c more nice refactoring 2012-11-10 13:00:13 -04:00
Joey Hess
7ab993ffc9 better data types allowed marvelous refactoring 2012-11-10 12:33:55 -04:00
Joey Hess
81953c2131 separate data type for push stages
This improves type safety.
2012-11-10 12:18:00 -04:00
Joey Hess
8b8964b523 refactor 2012-11-10 02:35:54 -04:00
Joey Hess
235f2ecb91 use a lookup table for speed 2012-11-10 02:18:19 -04:00
Joey Hess
2286032781 on second thought, do allow deferring StartingPush
My reasoning is that StartingPush could be received after another push
starts being received, and it would be better to respond to it afterwards
than not.
2012-11-10 01:41:28 -04:00
Joey Hess
16b2472574 refactor 2012-11-10 01:40:50 -04:00
Joey Hess
c0fab69f85 fix deferring of CanPush, and stop deferring StartingPush 2012-11-10 01:34:03 -04:00
Joey Hess
f57c2ef99e refactor 2012-11-10 00:24:26 -04:00
Joey Hess
0f8bbcc8fd refactor 2012-11-10 00:15:00 -04:00
Joey Hess
5fce2c013d refactor 2012-11-10 00:09:03 -04:00
Joey Hess
341d09adc2 fix exit code propigation 2012-11-10 00:02:55 -04:00
Joey Hess
ee0958e044 refactor 2012-11-09 23:52:51 -04:00
Joey Hess
c00ecfbb83 ensure handles get closed 2012-11-09 23:27:07 -04:00
Joey Hess
3f2467f253 increase chunk size
XMPP has no defined message size limits, but some servers will have ad-hoc
limits. However, 4k seems safe, even after the additional bloat of base64.
That should not exceed 8k.
2012-11-09 23:21:51 -04:00
Joey Hess
4a5e758a5a refactor 2012-11-09 23:17:47 -04:00
Joey Hess
6174c748af refactor 2012-11-09 23:12:54 -04:00
Joey Hess
6acc4fa83f avoid excessive debugging 2012-11-09 17:51:26 -04:00
Joey Hess
62fa648455 xmpp git push is working!
Various final bug fixes, and tweaks that got it working.

Currently pushes a hardcoded ref, which needs to be fixed, etc.
2012-11-09 17:40:59 -04:00
Joey Hess
1deda1db13 fix murderous typo 2012-11-09 17:33:34 -04:00
Joey Hess
47c032a748 run xmpp push actions in separate thread from xmpp client
Took me a while to figure out why the xmpp client was not receiving git xmpp
push messages after a push started.
2012-11-09 16:04:55 -04:00
Joey Hess
232b61e946 fix git push startup 2012-11-09 15:03:16 -04:00
Joey Hess
13547aa659 add canpush xmpp command 2012-11-09 14:34:06 -04:00
Joey Hess
82ccb385e3 use xmpp::user@host for xmpp remotes
Inject the required git-remote-xmpp into PATH when running xmpp git push.
Rest of the time it will not be in PATH, and git won't be able to talk to
xmpp remotes.
2012-11-09 13:35:23 -04:00
Joey Hess
29b72205bd blog for the day 2012-11-08 19:41:36 -04:00
Joey Hess
fb3b9412e4 xmpp push control flow
It might even work, although nothing yet triggers XMPP pushes.

Also added a set of deferred push messages. Only one push can run at a
time, and unrelated push messages get deferred. The set will never grow
very large, because it only puts two types of messages in there, that
can only vary in the client doing the push.
2012-11-08 16:46:29 -04:00
Joey Hess
08916ef695 rename 2012-11-08 14:06:43 -04:00
Joey Hess
0238e4ba07 hooked up XMPP git push send/receive (but not yet control flow) 2012-11-08 14:04:41 -04:00
Joey Hess
950c62e6fc data types and xml generation/parsing for xmpp push 2012-11-07 16:59:18 -04:00
Joey Hess
dbff2a1d73 better git-annex tag handling
Allow the tag to contain a value. Better extraction of the attribute value.
2012-11-07 15:47:30 -04:00
Joey Hess
b827afba03 rename another 'close' 2012-11-07 14:56:32 -04:00
Joey Hess
b8585a9452 NetManager is only currently used with dbus 2012-11-07 14:56:32 -04:00