Skip to content
Snippets Groups Projects
Commit 0e3bb972 authored by Max Melchert's avatar Max Melchert
Browse files

fix(makefile): support download file wildcards

parent 5e5f07ce
Branches
No related tags found
No related merge requests found
# Configuration
## Server
SERVER_USER := mmustermann # todo
SERVER_HOST := hyrican-1-extern # todo
SERVER_USER := mmustermann#TODO
SERVER_HOST := hyrican-1-extern#TODO
## Python Environment
SERVER_CONDA_PATH := /opt/conda
......@@ -17,16 +17,16 @@ PYTHON_PACKAGES := tensorflow-cpu ipympl mypy jupyter pystan \
## Project Paths
LOCAL_PROJECT_DIR := .
REMOTE_PROJECT_DIR := ~/akis/my_project # todo
REMOTE_PROJECT_DIR := ~/akis/my_project#TODO
## Project Files
MAIN_SCRIPT := main.py # todo
MAIN_SCRIPT := main.py#TODO
LOG_FILE := progress.log
## File Transfer
LOCAL_UPLOAD_FILES := . # todo
LOCAL_DOWNLOAD_DIR := download # todo
REMOTE_DOWNLOAD_FILES := output/* # todo
LOCAL_UPLOAD_FILES := .#TODO
LOCAL_DOWNLOAD_DIR := download#TODO
REMOTE_DOWNLOAD_FILES := output/*#TODO
## Misc
COPY_LINKS_AS_FILES := false
......@@ -73,7 +73,11 @@ log: # show the last lines of the log file
'
download: # download output files from server to client
$(RSYNC) $(LOGIN):$(REMOTE_PROJECT_DIR)/$(REMOTE_DOWNLOAD_FILES) $(LOCAL_PROJECT_DIR)/$(LOCAL_DOWNLOAD_DIR)
$(RSYNC) \
$(foreach dir,$(shell dirname $(REMOTE_DOWNLOAD_FILES)),--include='$(dir)') \
$(foreach file,$(REMOTE_DOWNLOAD_FILES),--include='$(file)') \
--exclude='*' \
$(LOGIN):$(REMOTE_PROJECT_DIR)/ $(LOCAL_PROJECT_DIR)/$(LOCAL_DOWNLOAD_DIR)
delete: # remove/delete all project files on server
$(SSH) '\
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment