Commit c1c79498 authored by Pontus Freyhult's avatar Pontus Freyhult

Use kom-default-{server,user-name,password} as user preferences

instead of lyskom-default-{server,user-name,password}.
parent e480e414
2004-11-03 Pontus Freyhult <pont@soua.net>
Use kom-default-* as user variables, not lyskom-default-*:
* vars.el.in (kom-default-server): Updated documentation and value.
(lyskom-default-server): Dito.
(kom-default-password): Dito.
(lyskom-default-password): Dito.
(kom-default-user-name): Dito.
(lyskom-default-user-name): Dito.
* startup.el (lyskom): Use kom-default-server, kom-default-user-name
and kom-default-password.
* commands1.el (kom-view-commented-text): Cleanup (progn removal),
inhibit immediate display of footnotes.
......
......@@ -82,7 +82,8 @@ clients of the event. See lyskom-mode for details on lyskom."
(interactive (list (lyskom-read-server-name
(lyskom-format 'server-q
(or (getenv "KOMSERVER")
lyskom-default-server)))
lyskom-default-server
kom-default-server)))
nil
nil
(if current-prefix-arg
......@@ -92,10 +93,14 @@ clients of the event. See lyskom-mode for details on lyskom."
(run-hooks 'lyskom-init-hook)
(setq username
(or username lyskom-default-user-name
(or username
lyskom-default-user-name
kom-default-user-name
(getenv "KOMNAME")))
(setq password
(or password lyskom-default-password
(or password
lyskom-default-password
kom-default-password
(getenv "KOMPASSWORD")))
(if (zerop (length host))
(let* ((env-kom (getenv "KOMSERVER"))
......@@ -103,7 +108,8 @@ clients of the event. See lyskom-mode for details on lyskom."
(lyskom-string-rassoc env-kom kom-builtin-server-aliases))))
(setq host (or (car canon)
env-kom
lyskom-default-server))))
lyskom-default-server
kom-default-server))))
(let ((port 4894)
(init-done nil))
(cond ;Allow "nanny:4892" to use port 4892.
......@@ -111,7 +117,7 @@ clients of the event. See lyskom-mode for details on lyskom."
(setq port (string-to-int (substring host (match-end 0))))
(cond
((zerop (match-beginning 0))
(setq host lyskom-default-server))
(setq host (or lyskom-default-server kom-default-server)))
(t
(setq host (substring host 0 (match-beginning 0)))))))
......
......@@ -4497,40 +4497,44 @@ the value of kom-tell-phrases for fun.")
;;; Externally defined variables (environment)
(defvar kom-default-server nil
"**Setting this variable does nothing. See `lyskom-default-server' instead.")
(def-kom-var lyskom-default-server "kom.lysator.liu.se"
(def-kom-var kom-default-server "kom.lysator.liu.se"
"**Default LysKOM server.
The value of this variable must be a string or `nil'. Instead of
setting this variable you may set the environment variable `KOMSERVER'.")
The value of this variable must be a string or `nil'."
local)
(defvar kom-default-user-name nil
"**Setting this variable does nothing. See `lyskom-default-user-name' instead.")
(def-kom-var lyskom-default-server nil
"**This variable is reserved for internal use. See
`kom-default-server' instead."
local)
(def-kom-var lyskom-default-user-name nil
(def-kom-var kom-default-user-name nil
"**Default LysKOM user name.
The value of this variable must be a string, integer indicating the
default user name, or `nil' to indicate no default. If set to an
integer, log in as the user with that conference number. If set to a
string, log in as the user with that name.
Instead of setting this variable you may set the environment variable
`KOMNAME' to the username to login as."
The value of this variable must be a string, indicating the
default user name, an integer indicating the conference number or
`nil' to indicate no default. If set to an integer, log in as the
user with that conference number. If set to a string, log in as the
user with that name."
local)
(defvar kom-default-password nil
"**Setting this variable does nothing. See `lyskom-default-password' instead.")
(def-kom-var lyskom-default-user-name nil
"**This variable is reserved for internal use. See
`kom-default-user-name' instead."
local)
(def-kom-var lyskom-default-password nil
(def-kom-var kom-default-password nil
"**Default LysKOM password.
The value of this variable must be a string or `nil'. There may be an
environment variable for this, but it shouldn't be used if there is."
local)
(def-kom-var lyskom-default-password nil
"**This variable is resvered for internal use. See
`kom-default-password' instead."
local)
(def-kom-var mode-line-conf-name nil
"Conf name that is present on the mode-line."
local)
......
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