Docker build
This commit is contained in:
parent
00000160d0
commit
00000170e4
3 changed files with 25 additions and 0 deletions
1
assignment-1/.gitignore
vendored
1
assignment-1/.gitignore
vendored
|
@ -1,2 +1,3 @@
|
|||
/target
|
||||
*.ppm
|
||||
*.zip
|
||||
|
|
23
assignment-1/Makefile
Normal file
23
assignment-1/Makefile
Normal file
|
@ -0,0 +1,23 @@
|
|||
.PHONY: clean
|
||||
|
||||
HANDIN := hw1a.michael.zhang.zip
|
||||
|
||||
BINARY := target/release/assignment-1
|
||||
|
||||
all: $(HANDIN)
|
||||
|
||||
$(BINARY):
|
||||
docker run \
|
||||
--rm \
|
||||
-v "$(shell pwd)":/usr/src/myapp \
|
||||
-v cargo-registry:/usr/local/cargo \
|
||||
--user "$(shell id -u)":"$(shell id -g)" \
|
||||
-w /usr/src/myapp \
|
||||
rust \
|
||||
cargo build --release
|
||||
|
||||
$(HANDIN): $(BINARY) Cargo.toml Cargo.lock README.md
|
||||
zip -r $@ src $<
|
||||
|
||||
clean:
|
||||
rm -f $(HANDIN) $(BINARY)
|
1
assignment-1/README.md
Normal file
1
assignment-1/README.md
Normal file
|
@ -0,0 +1 @@
|
|||
# Raycaster
|
Loading…
Reference in a new issue