summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2017-05-10 08:58:58 -0700
committerSean Whitton <spwhitton@spwhitton.name>2017-05-10 08:58:58 -0700
commita526f69d0e2908bdae2ff17a63641914c86547c3 (patch)
treea8306453ea5ecae78cc1528e95437dd307ab1cf7
parentc9d198ffa9d2719b83c07f5157e735dad801bb4e (diff)
parentbb15464e4218ff3209b6312e0795f60689613a2c (diff)
downloaddebug-me-a526f69d0e2908bdae2ff17a63641914c86547c3.tar.gz
Merge tag '1.20170509'
tagging package debug-me version 1.20170509
-rw-r--r--CHANGELOG6
-rw-r--r--Hash.hs2
-rw-r--r--Log.hs2
-rw-r--r--debug-me.13
-rw-r--r--debug-me.cabal4
-rw-r--r--doc/index.mdwn6
-rw-r--r--doc/news/version_1.20170505.mdwn3
-rw-r--r--doc/protocol/comment_1_44d3ac18bf10c1644a73855c01868ab3._comment19
-rw-r--r--doc/protocol/comment_2_4a25b8ee6e438a031e875078ffb1d125._comment10
-rw-r--r--doc/protocol/comment_3_6338e14886f146eb5d2f9c9316e1f7de._comment22
-rw-r--r--doc/todo/javascript_client.mdwn3
11 files changed, 71 insertions, 9 deletions
diff --git a/CHANGELOG b/CHANGELOG
index 9be378e..65f54c2 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,4 +1,4 @@
-debug-me (1.20170506) UNRELEASED; urgency=medium
+debug-me (1.20170509) unstable; urgency=medium
* Server: Use "postmaster" as default --from-email address
rather than "unknown@server".
@@ -7,8 +7,10 @@ debug-me (1.20170506) UNRELEASED; urgency=medium
Thanks, Sean Whitton.
* Avoid crash when --use-server is given an url that does not
include a path.
+ * Fix bug that prevented creating ~/.debug-me/log/remote/
+ when ~/.debug-me/ didn't already exist.
- -- Joey Hess <id@joeyh.name> Tue, 09 May 2017 11:45:41 -0400
+ -- Joey Hess <id@joeyh.name> Tue, 09 May 2017 19:20:32 -0400
debug-me (1.20170505) unstable; urgency=medium
diff --git a/Hash.hs b/Hash.hs
index 8a33803..a76e0b4 100644
--- a/Hash.hs
+++ b/Hash.hs
@@ -84,7 +84,7 @@ instance Hashable [Hash] where
hash = hash . B.concat . map (val . hashValue)
-- | Hash empty string for Nothing
-instance Hashable v => Hashable (Maybe v) where
+instance Hashable (Maybe Hash) where
hash Nothing = hash ()
hash (Just v) = hash v
diff --git a/Log.hs b/Log.hs
index 1bda5e1..1974b47 100644
--- a/Log.hs
+++ b/Log.hs
@@ -68,7 +68,7 @@ withSessionLogger subdir sessionid a = bracket setup cleanup go
setup = do
basedir <- logDir
let dir = maybe basedir (basedir </>) subdir
- createDirectoryIfMissing False dir
+ createDirectoryIfMissing True dir
return $ sessionLogFile dir sessionid
cleanup logfile = putStrLn $ "** debug-me session was logged to " ++ logfile
go logfile = withFile logfile WriteMode (a . mkLogger)
diff --git a/debug-me.1 b/debug-me.1
index 0ffb632..a0e108a 100644
--- a/debug-me.1
+++ b/debug-me.1
@@ -98,6 +98,9 @@ session is done.
.IP "~/.debug-me/log/"
Sessions are logged to here. The log file name is displayed when debug-me
exits.
+.IP "~/.debug-me/log/remote/"
+When using debug-me to connect to a remote session, the session will be
+logged to here.
.SH SEE ALSO
<https://debug-me.branchable.com/>
.PP
diff --git a/debug-me.cabal b/debug-me.cabal
index a7d2b15..10b184e 100644
--- a/debug-me.cabal
+++ b/debug-me.cabal
@@ -1,5 +1,5 @@
Name: debug-me
-Version: 1.20170505
+Version: 1.20170509
Cabal-Version: >= 1.8
Maintainer: Joey Hess <joey@kitenet.net>
Author: Joey Hess
@@ -11,7 +11,7 @@ Category: Utility
Build-Type: Custom
Synopsis: secure remote debugging
Description:
- Debugging a problem over email is slow, tedious, and hard. The developer
+ Debugging a problem over email/irc/BTS is slow, tedious, and hard. The developer
needs to see your problem to understand it. Debug-me aims to make debugging
fast, fun, and easy, by letting the developer access your computer remotely,
so they can immediately see and interact with the problem. Making your
diff --git a/doc/index.mdwn b/doc/index.mdwn
index 0bb7cbe..84bc344 100644
--- a/doc/index.mdwn
+++ b/doc/index.mdwn
@@ -11,9 +11,9 @@
[[!meta title="debug-me - secure remote debugging"]]
-Debugging a problem over email is slow, tedious, and hard. The developer
-needs to see the your problem to understand it. Debug-me aims to make
-debugging fast, fun, and easy, by letting the developer access your
+Debugging a problem over email/irc/BTS is slow, tedious, and hard. The
+developer needs to see the your problem to understand it. Debug-me aims to
+make debugging fast, fun, and easy, by letting the developer access your
computer remotely, so they can immediately see and interact with the
problem. Making your problem their problem gets it fixed fast.
diff --git a/doc/news/version_1.20170505.mdwn b/doc/news/version_1.20170505.mdwn
new file mode 100644
index 0000000..221b369
--- /dev/null
+++ b/doc/news/version_1.20170505.mdwn
@@ -0,0 +1,3 @@
+debug-me 1.20170505 released with [[!toggle text="these changes"]]
+[[!toggleable text="""
+ * First release of debug-me."""]] \ No newline at end of file
diff --git a/doc/protocol/comment_1_44d3ac18bf10c1644a73855c01868ab3._comment b/doc/protocol/comment_1_44d3ac18bf10c1644a73855c01868ab3._comment
new file mode 100644
index 0000000..64eed07
--- /dev/null
+++ b/doc/protocol/comment_1_44d3ac18bf10c1644a73855c01868ab3._comment
@@ -0,0 +1,19 @@
+[[!comment format=mdwn
+ username="https://www.joachim-breitner.de/"
+ nickname="nomeata"
+ avatar="http://cdn.libravatar.org/avatar/a2112893817513537c6a2c228c04c138a2f68bba57121ab7f267de58fc5171d7"
+ subject="Code smell in hashing"
+ date="2017-05-05T23:51:14Z"
+ content="""
+Hi Joey,
+
+I looked through http://source.debug-me.branchable.com/?p=source.git;a=blob;f=Hash.hs;hb=HEAD and since this probably scurity-relevant, allow me to be nitpicky:
+
+```
+instance Hashable v => Hashable (Maybe v) where
+ hash Nothing = hash ()
+ hash (Just v) = hash v
+```
+
+will hash the distinct values `Just ()` and `Nothing` identically. Maybe you don't have any `Maybe ()` type around, but in that case you should maybe document that requirement.
+"""]]
diff --git a/doc/protocol/comment_2_4a25b8ee6e438a031e875078ffb1d125._comment b/doc/protocol/comment_2_4a25b8ee6e438a031e875078ffb1d125._comment
new file mode 100644
index 0000000..935570d
--- /dev/null
+++ b/doc/protocol/comment_2_4a25b8ee6e438a031e875078ffb1d125._comment
@@ -0,0 +1,10 @@
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 2"""
+ date="2017-05-06T01:34:39Z"
+ content="""
+Thanks for that review. That would indeed be bad. To avoid that
+potential problem, I've specialized the instance to
+`Hashable (Maybe Hash)`, which is the only Maybe value that currently
+needs to be hashed.
+"""]]
diff --git a/doc/protocol/comment_3_6338e14886f146eb5d2f9c9316e1f7de._comment b/doc/protocol/comment_3_6338e14886f146eb5d2f9c9316e1f7de._comment
new file mode 100644
index 0000000..657a20a
--- /dev/null
+++ b/doc/protocol/comment_3_6338e14886f146eb5d2f9c9316e1f7de._comment
@@ -0,0 +1,22 @@
+[[!comment format=mdwn
+ username="https://www.joachim-breitner.de/"
+ nickname="nomeata"
+ avatar="http://cdn.libravatar.org/avatar/a2112893817513537c6a2c228c04c138a2f68bba57121ab7f267de58fc5171d7"
+ subject="comment 3"
+ date="2017-05-07T03:20:38Z"
+ content="""
+Still not good, I think, as the instance `Hashable Hash` has `hash = id`, so
+
+ hash Nothing
+ = hash ()
+ = id (hash ())
+ = hash (Just (hash ())
+
+ and we have a collision at type `Maybe Hash`.
+
+What would work is to do the same that `Hashable []` does, i.e. has the hash again:
+
+ hash (Just v) = hash (val (hashValue v))
+ hash Nothing = hash (mempty :: B.ByteString)
+
+"""]]
diff --git a/doc/todo/javascript_client.mdwn b/doc/todo/javascript_client.mdwn
new file mode 100644
index 0000000..72bf4da
--- /dev/null
+++ b/doc/todo/javascript_client.mdwn
@@ -0,0 +1,3 @@
+Since debug-me runs over websockets, it should be possible to compile it to
+javascript and produce a web page that can display and even interact with a
+debug-me session. Just an idea. --[[Joey]]