emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/dtache 5edde14d06 1/8: Rename log-size property to size


From: ELPA Syncer
Subject: [elpa] externals/dtache 5edde14d06 1/8: Rename log-size property to size
Date: Fri, 21 Jan 2022 10:57:29 -0500 (EST)

branch: externals/dtache
commit 5edde14d064052c9bccf3b49b0294a7d6551f606
Author: Niklas Eklund <niklas.eklund@posteo.net>
Commit: Niklas Eklund <niklas.eklund@posteo.net>

    Rename log-size property to size
---
 dtache.el           | 12 ++++++------
 test/dtache-test.el |  4 ++--
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/dtache.el b/dtache.el
index 73d6e97351..83b38b3c49 100644
--- a/dtache.el
+++ b/dtache.el
@@ -139,7 +139,7 @@ Valid values are: create, new and attach")
 (defvar dtache-metadata-annotators-alist nil
   "An alist of annotators for metadata.")
 
-(defconst dtache-session-version "0.3.2"
+(defconst dtache-session-version "0.3.3"
   "The version of `dtache-session'.
 This version is encoded as [package-version].[revision].")
 
@@ -241,7 +241,7 @@ This version is encoded as [package-version].[revision].")
   (action nil :read-only t)
   (time nil)
   (status nil)
-  (log-size nil)
+  (size nil)
   (state nil))
 
 ;;;; Commands
@@ -514,7 +514,7 @@ compilation or `shell-command' the command will also kill 
the window."
                                   :attachable (dtache-attachable-command-p 
command)
                                   :time `(:start ,(time-to-seconds 
(current-time)) :end 0.0 :duration 0.0 :offset 0.0)
                                   :status 'unknown
-                                  :log-size 0
+                                  :size 0
                                   :directory (concat (file-remote-p 
default-directory) dtache-session-directory)
                                   :host (dtache--host)
                                   :metadata (dtache-metadata)
@@ -855,7 +855,7 @@ Sessions running on  current host or localhost are updated."
                  (dtache--update-session-time session t))
            (dtache--session-state-transition-update session)))
         (t (progn
-             (setf (dtache--session-log-size session)
+             (setf (dtache--session-size session)
                    (file-attribute-size (file-attributes
                                          (dtache--session-file session 'log))))
              (dtache--db-update-entry session)))))
@@ -1001,7 +1001,7 @@ Optionally make the path LOCAL to host."
       (dtache--db-remove-entry session)
 
     ;; Update session
-    (setf (dtache--session-log-size session)
+    (setf (dtache--session-size session)
           (file-attribute-size
            (file-attributes
             (dtache--session-file session 'log))))
@@ -1165,7 +1165,7 @@ session and trigger a state transition."
 (defun dtache--size-str (session)
   "Return the size of SESSION's output."
   (file-size-human-readable
-   (dtache--session-log-size session)))
+   (dtache--session-size session)))
 
 (defun dtache--status-str (session)
   "Return string if SESSION has failed."
diff --git a/test/dtache-test.el b/test/dtache-test.el
index ae0e91b96c..baadd2c034 100644
--- a/test/dtache-test.el
+++ b/test/dtache-test.el
@@ -260,8 +260,8 @@
     (should (string= "May 08 08:49" (dtache--creation-str session)))))
 
 (ert-deftest dtache-test-size-str ()
-  (should (string= "100" (dtache--size-str (dtache--session-create :log-size 
100))))
-  (should (string= "1k" (dtache--size-str (dtache--session-create :log-size 
1024)))))
+  (should (string= "100" (dtache--size-str (dtache--session-create :size 
100))))
+  (should (string= "1k" (dtache--size-str (dtache--session-create :size 
1024)))))
 
 (ert-deftest dtache-test-status-str ()
   (should (string= "!" (dtache--status-str (dtache--session-create :status 
'failure))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]