mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
* src/bin/gnucash-make-guids.in: removed.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@6109 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
abff7140e4
commit
89ebeee6fa
@ -1,36 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
exec @-GNUCASH_RUN_SCRIPT-@ @-THIS_SCRIPT-@ "$@"
|
|
||||||
!#
|
|
||||||
|
|
||||||
(define (usage)
|
|
||||||
(display "Usage: gnucash-make-guids [number-to-make (default is 100)]\n")
|
|
||||||
(exit 1))
|
|
||||||
|
|
||||||
(define args (cdr (program-arguments)))
|
|
||||||
(define num-to-make 100)
|
|
||||||
|
|
||||||
;; Too many arguments
|
|
||||||
(if (> (length args) 1)
|
|
||||||
(usage))
|
|
||||||
|
|
||||||
(if (= (length args) 1)
|
|
||||||
(let ((arg (string->number (car args))))
|
|
||||||
(if (not (number? arg))
|
|
||||||
(usage))
|
|
||||||
(set! arg (inexact->exact arg))
|
|
||||||
(if (<= arg 0)
|
|
||||||
(usage))
|
|
||||||
(set! num-to-make arg)))
|
|
||||||
|
|
||||||
(use-modules (gnucash gnc-module))
|
|
||||||
(gnc:module-system-init)
|
|
||||||
(gnc:module-load "gnucash/engine" 0)
|
|
||||||
|
|
||||||
(let loop ((remaining num-to-make))
|
|
||||||
(display (gnc:guid-new)) (newline)
|
|
||||||
(if (> remaining 1)
|
|
||||||
(loop (- remaining 1))))
|
|
||||||
|
|
||||||
;; Local Variables:
|
|
||||||
;; mode: scheme
|
|
||||||
;; End:
|
|
Loading…
Reference in New Issue
Block a user