diff --git a/newLisp/.gitignore b/newLisp/.gitignore new file mode 100644 index 0000000..1c5cc7e --- /dev/null +++ b/newLisp/.gitignore @@ -0,0 +1 @@ +newlisp.exe diff --git a/newLisp/demo.lsp b/newLisp/demo.lsp new file mode 100644 index 0000000..41842ed --- /dev/null +++ b/newLisp/demo.lsp @@ -0,0 +1,18 @@ +; generate 1000 random numbers between 1 and 10 +; (true-random 1000 1 10) + +(println "About to do randos") +(define (true-random num from to) + (let (params (format "num=%d&min=%d&max=%d&" num from to) + pre "http://www.random.org/integers/?" + post "col=1&base=10&format=plain&rnd=new") + (println pre params post) + (map int (parse (get-url (append pre params post)))) + + ) +) +; + +(println "Randos Done!") +(exit) + diff --git a/newLisp/helloworld.lsp b/newLisp/helloworld.lsp new file mode 100644 index 0000000..33f0f51 --- /dev/null +++ b/newLisp/helloworld.lsp @@ -0,0 +1,2 @@ +(println "Hello World!") +(exit) \ No newline at end of file diff --git a/newLisp/htmlOfAllLinks.lsp b/newLisp/htmlOfAllLinks.lsp new file mode 100644 index 0000000..ae05412 --- /dev/null +++ b/newLisp/htmlOfAllLinks.lsp @@ -0,0 +1,11 @@ +; write links.html with all links in page + +(setq page (get-url "http://www.newlisp.org/")) +(println "About to grab links") +(write-file "links.html" + (join (find-all + "]+)>([^>]*)" page) + "
\n")) +; +(println "should be done now") +(exit) \ No newline at end of file diff --git a/newLisp/ip.cmd b/newLisp/ip.cmd new file mode 100644 index 0000000..d73b7ae --- /dev/null +++ b/newLisp/ip.cmd @@ -0,0 +1,21 @@ + +# begin newlisp-program +; get all IPs assigned to this machine on Win32 + +(define (get-ips , ips) + (println "getting Ips") + (dolist (ln (exec "ipconfig")) + (if (find + {\b\d{1,3}\.\d{,3}\.\d{1,3}\.\d{1,3}\b} ln 0) + (push $0 ips) + ) + ) + ips +) +; + +(println "IPs: " ips) + +(println "Hello") +(exit) +# end newlisp-program diff --git a/newLisp/ip.lsp b/newLisp/ip.lsp new file mode 100644 index 0000000..ddc701a --- /dev/null +++ b/newLisp/ip.lsp @@ -0,0 +1,17 @@ +; get all IPs assigned to this machine on Win32 + +(define (get-ips , ips) + (println "getting Ips") + (dolist (ln (exec "ipconfig")) + (if (find + {\b\d{1,3}\.\d{,3}\.\d{1,3}\.\d{1,3}\b} ln 0) + (push $0 ips) + ) + ) + ips +) +; + +(println "IPs: " ips) + +(println "Hello") diff --git a/newLisp/links.html b/newLisp/links.html new file mode 100644 index 0000000..0a8c87b --- /dev/null +++ b/newLisp/links.html @@ -0,0 +1,26 @@ +Home
+About
+Downloads
+Docs
+ Modules
+Links
+Tips&Tricks
+C-Libs
+Apps
+May 12th, 2019
+new LISP
+differs from other LISPs
+Movie
+Slideshow
+newLISP in a Browser
+Documented
+API
+modules
+C-libraries
+Editors
+GPL
+features
+Twitter
+Share
+Site
+newLISP \ No newline at end of file diff --git a/newLisp/readme.md b/newLisp/readme.md new file mode 100644 index 0000000..56ef6f3 --- /dev/null +++ b/newLisp/readme.md @@ -0,0 +1,4 @@ +Copy newlisp.exe into this folder (it wont commit since its in the gitignore) + + +* [newLISP website](http://www.newlisp.org/index.cgi?Home) \ No newline at end of file