Commit 910363fc authored by David Byers's avatar David Byers
Browse files

Minor fixes.

kom-bug-report is back in talkback.el
parent 12116977
2000-08-17 David Byers <davby@ida.liu.se>
Reimplement kom-bug-report:
* talkback.el: New file.
(kom-bug-report): I'm baaaack!
Misc fixes:
* swedish-strings.el (lyskom-command): Lista organisatörsskap
changed to Lista ägda möten.
(lyskom-custom-strings): Fixed typo.
* commands1.el (kom-list-created-conferences): Ugly hack to fix
cursor positioning problem. Something is badly broken here.
* lyskom-rest.el (lyskom-is-loaded): Encode frame title string to
latin1.
* vars.el.in (lyskom-mule-compiled): New variable.
* commands2.el (kom-who-am-i): Print MULE indicator for Emacs and
client.
2000-08-16 Kent Engström <kent@ceres.unit.liu.se>
* Makefile, lyskom-elisp-client.spec: Support for building RPMS.
......
......@@ -95,6 +95,7 @@ SOURCES = $(LANGUAGE-EL) \
menus.el slow.el \
elib-string.el \
option-edit.el \
talkback.el \
lyskom-rest.el
HEADER = defvar.el \
......
......@@ -1444,7 +1444,7 @@ Those that you are not a member in will be marked with an asterisk."
(blocking-do 'get-uconf-stat lyskom-pers-no)
(let ((pers (lyskom-read-conf-stat
(if arg 'list-pers-confs-created-by 'list-confs-created-by)
'(pers)
'(all)
nil
(if (cache-get-uconf-stat lyskom-pers-no)
(cons (conf-stat->name (cache-get-uconf-stat lyskom-pers-no)) 0)1
......@@ -1460,9 +1460,11 @@ Those that you are not a member in will be marked with an asterisk."
1
(length (conf-z-info-list->conf-z-infos result))
0))
(calls nil))
(calls nil)
(was-at-max (= (save-excursion (end-of-line) (point)) (point-max))))
(condition-case arg
(progn (lyskom-traverse conf-z (conf-z-info-list->conf-z-infos result)
(progn
(lyskom-traverse conf-z (conf-z-info-list->conf-z-infos result)
(setq calls (cons
(initiate-get-conf-stat 'main
'lyskom-list-created-conferences-2
......@@ -1473,9 +1475,13 @@ Those that you are not a member in will be marked with an asterisk."
)
calls)))
(lyskom-wait-queue 'main)
(when (eq 0 (elt counter 3))
(lyskom-format-insert 'no-created-confs pers))
)
(if (eq 0 (elt counter 3))
(lyskom-format-insert 'no-created-confs pers)
(let ((window (get-buffer-window (current-buffer))))
(if (and window was-at-max)
(if (pos-visible-in-window-p (point-max) window)
(goto-char (point-max))
(and kom-continuous-scrolling (lyskom-scroll)))))))
(quit (aset counter 0 t)
(lyskom-cancel-call 'main calls))))
(lyskom-insert (lyskom-get-string (if arg 'no-pers-confs-exist 'no-confs-exist))))
......
......@@ -1133,10 +1133,12 @@ Format is 23:29 if the text is written today. Otherwise 04-01."
(version-info->software-version lyskom-server-version-info))
(lyskom-format-insert 'who-i-am-client
lyskom-clientversion)
lyskom-clientversion
lyskom-mule-compiled)
(lyskom-format-insert 'who-i-am-emacs
(emacs-version)))
(emacs-version)
enable-multibyte-characters))
......
......@@ -83,6 +83,7 @@ SOURCES = $(LANGUAGE-EL) \
menus.el slow.el \
elib-string.el \
option-edit.el \
talkback.el \
lyskom-rest.el
HEADER = defvar.el \
......
......@@ -332,16 +332,16 @@ and you have finished reading. Please come back later.
(no-matching-anys . "No persons or conferences match \"%#1s\".\n")
(no-confs-exist . "There are no conferences in the database.\n")
(no-pers-confs-exist . "There are no persons or conferences in the database.\n")
(list-confs-created-by . "List conferences administered by: ")
(listing-confs-created-by . "Listing conferences administered by %#1P\
(list-confs-created-by . "List owned conferences for: ")
(listing-confs-created-by . "Listing owned conferences for %#1P\
C=Created, O=Supervisor, S=Letterbox is super conf; S=Secret, P=Protected\n")
(list-pers-confs-created-by . "List persons and conferences administered by: ")
(list-pers-confs-created-by . "List owned conferences and persons for: ")
(getting-all-confs . "Retrieving a list of all conferences from the server...")
(getting-all-pers-confs . "Retrieving a list of all persons and conferences from the server...")
(getting-all-confs-done . "Retrieving a list of all conferences from the server...done")
(getting-all-pers-confs-done . "Retrieving a list of all persons and conferences from the server...done")
(finding-created-confs . "Finding administered conferences (%#1d av %#2d done)")
(finding-created-pers-confs . "Finding administered persons and conferences (%#1d av %#2d done)")
(finding-created-confs . "Finding owned conferences (%#1d av %#2d done)")
(finding-created-pers-confs . "Finding owned persons and conferences (%#1d av %#2d done)")
(no-created-confs . "%#1P is not creator, supervisor or super conference for any conference.\n")
(name-to-be-changed . "Name to change: ")
......@@ -1215,9 +1215,9 @@ Text:
(who-i-am-not-present . "%#1P (not in any conference) \n")
(who-i-am-present . "%#1P is present in %#2M\n")
(who-i-am-client . "The programs is lyskom.el, version %#1s.\n")
(who-i-am-client . "The programs is lyskom.el, version %#1s%#2?b%[ (MULE)%]%[%].\n")
(who-i-am-server . "This is %#1s, version %#2s.\n")
(who-i-am-emacs . "Running under %#1s.\n")
(who-i-am-emacs . "Running under %#1s%#2?b%[ (MULE)%]%[%].\n")
(no-such-session-r . "That session does not exist. Perhaps the user is not logged on.\n")
(person-not-logged-in-r . "%#1P is not logged on.\n")
......@@ -1536,7 +1536,7 @@ You must become an active member of the conference to enter it.\n")
(kom-go-to-conf . "Go (to) conference")
(kom-go-to-next-conf . "(Go to) next conference")
(kom-jump . "Skip (all) comments")
(kom-list-created-conferences . "List administered conferences")
(kom-list-created-conferences . "List owned conferences")
(kom-list-conferences . "List conferences")
(kom-list-persons . "List users")
(kom-list-news . "List news")
......
......@@ -3575,8 +3575,8 @@ One parameter - the prompt string."
`(kom-show-unread-in-frame-title
(lyskom-session-has-unreads
(" ("
((lyskom-session-has-unreads ,(lyskom-get-string 'frame-title-unread))
(lyskom-session-has-unread-letters ,(lyskom-get-string 'frame-title-letters)))
((lyskom-session-has-unreads (encode-coding-string ,(lyskom-get-string 'frame-title-unread) 'iso-8859-1))
(lyskom-session-has-unread-letters (encode-coding-string ,(lyskom-get-string 'frame-title-letters) 'iso-8859-1)))
")"))))
(add-hook 'kill-buffer-hook 'lyskom-remove-buffer-from-lists)
......
......@@ -313,16 +313,16 @@ du har l
(no-matching-anys . "Inga personer eller mten uppfyller uttrycket \"%#1s\".\n")
(no-confs-exist . "Det finns inga mten i databasen.\n")
(no-pers-confs-exist . "Det finns inga mten eller personer i databasen.\n")
(list-confs-created-by . "Lista organisatrsskap fr: ")
(listing-confs-created-by . "Organisatrsskap fr %#1P\n\
(list-confs-created-by . "Lista gda mten fr: ")
(listing-confs-created-by . "gda mten fr %#1P\n\
S=Skapat, O=Organisatr, M=Brevlda som supermte; S=Slutet, H=Hemligt\n")
(list-pers-confs-created-by . "Lista organisatrsskap (med brevldor) fr: ")
(list-pers-confs-created-by . "Lista gda mten (med brevldor) fr: ")
(getting-all-confs . "Hmtar en lista av alla mten frn servern...")
(getting-all-pers-confs . "Hmtar en lista av alla personer och mten frn servern...")
(getting-all-confs-done . "Hmtar en lista av alla mten frn servern...klart")
(getting-all-pers-confs-done . "Hmtar en lista av alla personer och mten frn servern...klart")
(finding-created-confs . "Sker organisatrsskap (%#1d av %#2d klart)")
(finding-created-pers-confs . "Sker organisatrsskap (med brevldor) (%#1d av %#2d klart)")
(finding-created-confs . "Sker gda mten (%#1d av %#2d klart)")
(finding-created-pers-confs . "Sker gda mten (med brevldor) (%#1d av %#2d klart)")
(no-created-confs . "%#1P r inte skapare, organisatr eller supermte fr ngot mte.\n")
(name-to-be-changed . "Ange det namn som skall ndras: ")
......@@ -1219,9 +1219,9 @@ Text:
(who-i-am-not-present . "%#1P r inte nrvarande i ngot mte\n")
(who-i-am-present . "%#1P r nrvarande i %#2M\n")
(who-i-am-client . "Programmet heter lyskom.el, version %#1s.\n")
(who-i-am-client . "Programmet heter lyskom.el, version %#1s%#2?b%[ (MULE)%]%[%].\n")
(who-i-am-server . "Detta r %#1s, version %#2s.\n")
(who-i-am-emacs . "Det krs under %#1s.\n")
(who-i-am-emacs . "Det krs under %#1s%#2?b%[ (MULE)%]%[%].\n")
(no-such-session-r . "Det finns ingen sdan session. Personen kanske inte r inloggad.\n")
(person-not-logged-in-r . "%#1P r inte inloggad.\n")
......@@ -1539,7 +1539,7 @@ Du m
(kom-go-to-conf . "G till mte")
(kom-go-to-next-conf . "G till nsta mte")
(kom-jump . "Hoppa ver alla kommentarer")
(kom-list-created-conferences . "Lista organisatrsskap")
(kom-list-created-conferences . "Lista gda mten")
(kom-list-conferences . "Lista mten")
(kom-list-persons . "Lista personer")
(kom-list-news . "Lista nyheter")
......@@ -2899,7 +2899,7 @@ i servern. Annars sparas det i din .emacs.")
(kom-permissive-completion-doc . "\
Om detta r pslaget s kommer TAB bara att fylla ut namn p inloggade
personer nr kommandot bara kan utfras p inloggade personer (till
exempel Status (fr) session och Snda messelande.) Om det r avslaget
exempel Status (fr) session och Snda meddelande.) Om det r avslaget
kommer TAB att fylla ut ven med namn p personer som inte r inloggade.")
......
;;;;; -*-coding: raw-text;-*-
;;;;;
;;;;; $Id$
;;;;; Copyright (C) 1991, 1996 Lysator Academic Computer Association.
;;;;;
;;;;; This file is part of the LysKOM server.
;;;;;
;;;;; LysKOM is free software; you can redistribute it and/or modify it
;;;;; under the terms of the GNU General Public License as published by
;;;;; the Free Software Foundation; either version 2, or (at your option)
;;;;; any later version.
;;;;;
;;;;; LysKOM is distributed in the hope that it will be useful, but WITHOUT
;;;;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
;;;;; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
;;;;; for more details.
;;;;;
;;;;; You should have received a copy of the GNU General Public License
;;;;; along with LysKOM; see the file COPYING. If not, write to
;;;;; Lysator, c/o ISY, Linkoping University, S-581 83 Linkoping, SWEDEN,
;;;;; or the Free Software Foundation, Inc., 675 Mass Ave, Cambridge,
;;;;; MA 02139, USA.
;;;;;
;;;;; Please mail bug reports to bug-lyskom@lysator.liu.se.
;;;;;
;;;; ================================================================
;;;; ================================================================
;;;;
;;;; File: talkback.el
;;;;
;;;; Functions for handing bug reports
;;;;
(setq lyskom-clientversion-long
(concat lyskom-clientversion-long
"$Id$\n"))
(defvar kom-bug-report-address "kom@lysator.liu.se")
(defvar lyskom-bug-report-special-vars
'((lyskom-conf-cache . (lambda (n v) (format "%d items" (length v))))
(lyskom-uconf-cache . (lambda (n v) (format "%d items" (length v))))
(lyskom-text-cache . (lambda (n v) (format "%d items" (length v))))
(lyskom-text-mass-cache . (lambda (n v) (format "%d items" (length v))))
(lyskom-default-password . "********")))
(defun lyskom-save-backtrace (&rest data)
"Save the current backtrace"
(lyskom-message "Saving debugging information...")
(setq lyskom-backtrace-list (cons (list (current-time-string)
(let* ((buffer (generate-new-buffer " *Backtrace*"))
(standard-output buffer))
(backtrace)
(prog1 (save-excursion
(set-buffer buffer)
(buffer-string))
(kill-buffer buffer)))
data)
lyskom-backtrace-list))
(lyskom-message "Saving debugging information...done"))
(defun lyskom-bug-insert-recent-messages (n)
(let ((message-buf (get-buffer (lyskom-xemacs-or-gnu " *Message-Log*"
"*Messages*"))))
(insert "\n\nRecent messages:\n")
(if message-buf
(insert-buffer-substring message-buf
(save-excursion
(set-buffer message-buf)
(goto-char (point-max))
(forward-line -10)
(point))
(save-excursion
(set-buffer message-buf)
(point-max))))))
(defun lyskom-insert-bug-report ()
(insert
(save-excursion
(set-buffer lyskom-buffer)
(let ((v lyskom-server-version-info))
(format "\
This bug report will be sent to the LysKOM development team,
not to your local site managers.
Please write in english or swedish, because the LysKOM maintainers (if
there are any) are too lazy to learn other languages just so they can
read your bug reports.
Client time: %s
Emacs version: %s (%s)
Client version: %s (%s)
LysKOM server: %s:%S
Server version: %s %s %S
Current person: %S (%s)
Please describe the precise symptoms of the bug and exactly what
actions triggered the bug. Be as detailed as possible. Do not try to
make any conclusions of your own.
"
(current-time-string)
(emacs-version)
(if enable-multibyte-characters "MULE" "no MULE")
lyskom-clientversion
(if lyskom-mule-compiled "MULE" "no MULE")
lyskom-server-name
lyskom-server-port
(if v (version-info->server-software v) "unknown")
(if v (version-info->software-version v) "unknown")
(if v (version-info->protocol-version v) "unknown")
lyskom-pers-no
(condition-case nil
(uconf-stat->name (cache-get-uconf-stat lyskom-pers-no))
(error ""))
))))
(let ((saved-place (point)))
(insert "\n\n")
(lyskom-bug-insert-recent-messages 20)
(insert "\n\nSaved backtraces:\n\n")
(mapcar (lambda (el)
(insert (elt el 0)) ; Time
(insert "\n")
(insert (elt el 1)) ; Backtrace
(insert "\n")
(mapcar (lambda (data)
(insert "Data: ")
(prin1 data)
(insert "\n"))
(elt el 2)))
lyskom-backtrace-list)
(insert "\n\nAll variables:\n\n")
(mapatoms
(lambda (var)
(when (and (save-excursion (set-buffer lyskom-buffer) (boundp var))
(or (string-match "^\\(lys\\)?kom" (symbol-name var))))
(message "Collecting system information...%s" var)
(insert (format "(%s " var))
(cond ((assq var lyskom-bug-report-special-vars)
(let ((fn (cdr (assq var lyskom-bug-report-special-vars))))
(cond ((functionp fn) (lyskom-bug-report-insert-value (funcall fn var (lyskom-default-value var))))
(t (lyskom-bug-report-insert-value fn)))))
(t (lyskom-bug-report-insert-value (lyskom-default-value var))))
(insert ")\n"))))
(goto-char saved-place)
))
(defun lyskom-bug-report-insert-value (v)
(cond ((eq t v) (insert "t"))
((eq nil v) (insert "nil"))
((symbolp v) (insert "'") (princ v))
(t (prin1 v))))
(defun kom-bug-report (topic)
"Report a LysKOM bug"
(interactive "sBug Subject: ")
(let ((buf lyskom-buffer))
(unless buf
(error "Switch to a LysKOM buffer to report bugs."))
(when (lyskom-xemacs-or-gnu
(progn (compose-mail kom-bug-report-address topic) t)
(mail nil kom-bug-report-address topic))
(goto-char (point-min))
(re-search-forward (concat "^" (regexp-quote mail-header-separator) "\n\
"))
(let ((standard-output (current-buffer)))
(message "Collecting system information...")
(make-local-variable 'lyskom-buffer)
(setq lyskom-buffer buf)
(lyskom-insert-bug-report)
(message "Collecting system information...done")))))
......@@ -35,6 +35,11 @@
(concat lyskom-clientversion-long
"$Id$\n"))
(defvar lyskom-mule-compiled
(eval-when-compile (and (boundp 'enable-multibyte-characters)
enable-multibyte-characters))
"Non-nil if the client was compiled with multibyte characters enabled")
(provide 'lyskom)
(require 'lyskom-defvar "defvar")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment