mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
* src/scm/command-line.scm: add other env var lookups as part of
startup changes. Change bootstrap to main. (gnc:*load-path*): eliminate. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@6208 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
8bd0c6e52f
commit
7e23822bb3
@ -52,16 +52,14 @@
|
||||
(N_ "Configuration directory - can be overridden with GNC_CONFIG_DIR environment variable.")
|
||||
(lambda (var value) (if (string? value) (list value) #f))
|
||||
string=?
|
||||
(if (getenv "GNC_CONFIG_DIR")
|
||||
(getenv "GNC_CONFIG_DIR")
|
||||
gnc:_config-dir-default_)))
|
||||
gnc:_install-config-dir_))
|
||||
|
||||
(define gnc:*share-dir*
|
||||
(gnc:make-config-var
|
||||
(N_ "Shared files directory.")
|
||||
(lambda (var value) (if (string? value) (list value) #f))
|
||||
string=?
|
||||
gnc:_share-dir-default_))
|
||||
gnc:_install-share-dir_))
|
||||
|
||||
;; Convert the temporary startup value into a config var.
|
||||
(let ((current-value gnc:*debugging?*))
|
||||
@ -91,24 +89,6 @@
|
||||
eq?
|
||||
#f))
|
||||
|
||||
;; Convert the temporary startup value into a config var.
|
||||
(let ((current-load-path gnc:*load-path*))
|
||||
(set!
|
||||
gnc:*load-path*
|
||||
(gnc:make-config-var
|
||||
(N_ "A list of strings indicating the load path for (gnc:load name).
|
||||
Each element must be a string representing a directory or a symbol
|
||||
where 'default expands to the default path, and 'current expands to
|
||||
the current value of the path.")
|
||||
(lambda (var value)
|
||||
(let ((result (gnc:expand-load-path value)))
|
||||
(if (list? result)
|
||||
(list result)
|
||||
#f)))
|
||||
equal?
|
||||
'(default)))
|
||||
(gnc:config-var-value-set! gnc:*load-path* #f current-load-path))
|
||||
|
||||
(define gnc:*doc-path*
|
||||
|
||||
(gnc:make-config-var
|
||||
@ -190,19 +170,6 @@ the current value of the path.")
|
||||
"SHAREDIR"
|
||||
(N_ "Set shared directory"))
|
||||
|
||||
(list "load-path"
|
||||
'string
|
||||
(lambda (val)
|
||||
(let ((path-list
|
||||
(call-with-input-string val (lambda (port) (read port)))))
|
||||
(if (list? path-list)
|
||||
(gnc:config-var-value-set! gnc:*load-path* #f path-list)
|
||||
(begin
|
||||
(gnc:error "non-list given for --load-path: " val)
|
||||
(gnc:shutdown 1)))))
|
||||
"LOADPATH"
|
||||
(N_ "Set the search path for .scm files."))
|
||||
|
||||
(list "doc-path"
|
||||
'string
|
||||
(lambda (val)
|
||||
|
Loading…
Reference in New Issue
Block a user