-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
40 lines (32 loc) · 966 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# TODO differentiate WSL Linux and Linux see:
# https://stackoverflow.com/questions/38086185/how-to-check-if-a-program-is-run-in-bash-on-ubuntu-on-windows-and-not-just-plain
UNAME := $(shell uname -s)
SYSTEM = Linux
ifeq ($(UNAME),Linux)
ifeq ($(WSL),1)
SYSTEM = 'WSL'
endif
else
ifeq ($(UNAME),Darwin)
SYSTEM = 'Mac'
else
SYSTEM = 'Windows'
endif
endif
info:
@echo $(UNAME), $(WSL), $(SYSTEM), $(DOCKER_HOST_IP)
install_yarn:
ifeq (,$(shell which yarn))
npm -g install yarn
endif
install_js:
cd ingest && yarn && cd ..
#This expects a command line argument defining the data directory such as make load_share_data DATADIR=../data/EarthArXiv
load_share_data_fetched_from_api:
cd ingest && ts-node loadShareDataFetchedFromAPI.ts && cd ..
load_share_data_from_dump:
cd ingest && ts-node loadShareDataFromDataDump.ts && cd ..
fetch_share_data:
cd ingest && ts-node fetchShareData.ts && cd ..
install: install_yarn install_js
echo 'Installing'