updated CSV export url
updated makefile to reflect new standard lisp makefile
This commit is contained in:
parent
94ef142b97
commit
f82870ab9c
30
Makefile
30
Makefile
|
@ -1,22 +1,16 @@
|
|||
LISPS = ros sbcl clisp cmucl ccl
|
||||
CMDS = --eval "(ql:quickload :df-bug-bot)" --eval "(asdf:make :df-bug-bot)" --eval "(quit)"
|
||||
define LISP_CMDS
|
||||
"(handler-case \
|
||||
(progn (ql:quickload :df-bug-bot) \
|
||||
(asdf:make :df-bug-bot)) \
|
||||
(error (e) \
|
||||
(format t \"~A~%\" e) \
|
||||
(uiop:quit 1)))"
|
||||
endef
|
||||
|
||||
|
||||
ifeq ($(OS),Windows_NT)
|
||||
LISP := $(foreach lisp,$(LISPS), \
|
||||
$(shell where $(lisp)) \
|
||||
$(if $(.SHELLSTATUS),$(strip $(lisp)),))
|
||||
else
|
||||
LISP := $(foreach lisp,$(LISPS), \
|
||||
$(if $(findstring $(lisp),"$(shell which $(lisp) 2>/dev/null)"), $(strip $(lisp)),))
|
||||
endif
|
||||
|
||||
ifeq ($(LISP),)
|
||||
$(error "No lisps found")
|
||||
endif
|
||||
.PHONY: clean all
|
||||
|
||||
all:
|
||||
$(LISP) $(CMDS)
|
||||
ros --eval $(LISP_CMDS)
|
||||
|
||||
clean:
|
||||
test -d bin && rm bin/df-bug-bot
|
||||
clean:
|
||||
rm -ri bin/
|
|
@ -14,6 +14,8 @@
|
|||
"regex used for pre-processing the downloaded CSV file")
|
||||
(defvar *recent-ids* nil
|
||||
"a list containing the 5 most recent bug ids")
|
||||
(defvar *bug-tracker-url* "https://dwarffortressbugtracker.com/csv_export.php"
|
||||
"link to the DF bug tracker CSV export")
|
||||
|
||||
(defun reinitizalize-random-state ()
|
||||
"reinitializes the random state with a new one"
|
||||
|
@ -32,7 +34,7 @@
|
|||
|
||||
(defun refresh-csv-file ()
|
||||
"downloads the bug CSV file and writes it to *CSV-FILE*"
|
||||
(let ((csv-string (drakma:http-request "https://dwarffortress.mantishub.io/csv_export.php")))
|
||||
(let ((csv-string (drakma:http-request *bug-tracker-url*)))
|
||||
(str:to-file *csv-file*
|
||||
(str:join (string #\newline)
|
||||
(parse-csv csv-string)))
|
||||
|
|
Loading…
Reference in New Issue