aboutsummaryrefslogtreecommitdiff
path: root/lux-scheme/source
diff options
context:
space:
mode:
authorEduardo Julian2021-05-30 19:33:34 -0400
committerEduardo Julian2021-05-30 19:33:34 -0400
commit38c2eb5d39838e415a8c1f51b79099086b391a22 (patch)
tree6d4ad65a1741340e6763353de06ecec7f3a12b2c /lux-scheme/source
parent7a2ab85f1c86e7256c5b45672b2fe8f157e35c9a (diff)
Giving up on Kawa for now...
Diffstat (limited to 'lux-scheme/source')
-rw-r--r--lux-scheme/source/program.lux29
1 files changed, 7 insertions, 22 deletions
diff --git a/lux-scheme/source/program.lux b/lux-scheme/source/program.lux
index 24d26945d..d71daa6e7 100644
--- a/lux-scheme/source/program.lux
+++ b/lux-scheme/source/program.lux
@@ -25,6 +25,8 @@
[number (#+ hex)
["n" nat]
["." i64]]]
+ [time
+ ["." instant]]
["." world #_
["." file]
["#/." program]]
@@ -57,7 +59,7 @@
["." platform (#+ Platform)]]
[meta
["." packager #_
- ["#" script]]]]]]
+ ["#" scheme]]]]]]
[program
["/" compositor
["#." cli]
@@ -442,24 +444,11 @@
(-> Any (Promise Any))
(promise.future (\ world/program.default exit +0)))
-(def: (then pre post)
- (-> _.Expression _.Expression _.Expression)
- (_.manual (format (_.code pre)
- text.new_line
- (_.code post))))
-
-(def: (scope body)
- (-> _.Expression _.Expression)
- (let [@program (_.var "lux_program")]
- ($_ ..then
- (_.define_function @program [(list) #.None] body)
- (_.apply/* (list) @program)
- )))
-
(`` (program: [{service /cli.service}]
(let [extension ".scm"]
(do io.monad
- [platform ..platform]
+ [platform ..platform
+ now instant.now]
(exec (do promise.monad
[_ (/.compiler {#/static.host @.scheme
#/static.host_module_extension extension
@@ -474,13 +463,9 @@
[_.Var _.Expression _.Expression]
..extender
service
- [(packager.package (_.manual "")
- _.code
- ..then
- ..scope)
+ [(packager.package now)
(format (/cli.target service)
(\ file.default separator)
- "program"
- extension)])]
+ "program.tar")])]
(..declare_success! []))
(io.io []))))))