test: add alternate binRoot example (called main)
This commit is contained in:
parent
3c1185dc9c
commit
b4dcad59fa
8 changed files with 25 additions and 1 deletions
|
|
@ -2,7 +2,7 @@ LAKE := ../build/bin/lake
|
|||
|
||||
all: check-lake test time-bootstrap check-bootstrap test-bootstrapped
|
||||
|
||||
test: test-init test-hello test-io test-deps test-git test-ffi
|
||||
test: test-init test-hello test-io test-deps test-git test-ffi test-main
|
||||
|
||||
check-lake:
|
||||
$(LAKE) self-check
|
||||
|
|
@ -25,6 +25,9 @@ test-git:
|
|||
test-ffi:
|
||||
cd ffi && ./test.sh
|
||||
|
||||
test-main:
|
||||
cd main && ./test.sh
|
||||
|
||||
test-bootstrap:
|
||||
cd bootstrap && ./test.sh
|
||||
|
||||
|
|
|
|||
1
examples/main/.gitignore
vendored
Normal file
1
examples/main/.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
/build
|
||||
1
examples/main/Lib/Foo.lean
Normal file
1
examples/main/Lib/Foo.lean
Normal file
|
|
@ -0,0 +1 @@
|
|||
def foo := "foo"
|
||||
4
examples/main/Main.lean
Normal file
4
examples/main/Main.lean
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
import Lib.Foo
|
||||
|
||||
def main :=
|
||||
IO.println s!"Hello, {foo}!"
|
||||
1
examples/main/clean.sh
Executable file
1
examples/main/clean.sh
Executable file
|
|
@ -0,0 +1 @@
|
|||
rm -rf build
|
||||
8
examples/main/package.lean
Normal file
8
examples/main/package.lean
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
import Lake.Package
|
||||
|
||||
def package : Lake.PackageConfig := {
|
||||
name := "foo"
|
||||
version := "1.0"
|
||||
moduleRoot := `Lib
|
||||
binRoot := `Main
|
||||
}
|
||||
1
examples/main/package.sh
Executable file
1
examples/main/package.sh
Executable file
|
|
@ -0,0 +1 @@
|
|||
../../build/bin/lake build-bin
|
||||
5
examples/main/test.sh
Executable file
5
examples/main/test.sh
Executable file
|
|
@ -0,0 +1,5 @@
|
|||
set -e
|
||||
|
||||
./clean.sh
|
||||
./package.sh
|
||||
./build/bin/foo
|
||||
Loading…
Add table
Reference in a new issue