Revision 3387
Added by Aaron Marcuse-Kubitza over 12 years ago
input.Makefile | ||
---|---|---|
248 | 248 |
+maps = $(filter maps/% $(mappings)/%,$(+_)) |
249 | 249 |
<in = $(firstword $(filter-out $(+maps),$(+_))) |
250 | 250 |
map = $(if $(<in),<$(<in),\ |
251 |
$(if $(use_staged),env in_database=vegbien in_schema=$(datasrc) in_table=$*,\ |
|
252 | 251 |
$(if $(srcs),$(withCatSrcs),\ |
253 | 252 |
$(if $(mapEnv),env $(mapEnv),\ |
254 |
$(error No input file src/*.$*.{$(exts)})))))\
|
|
253 |
$(error No input file src/*.$*.{$(exts)}))))\ |
|
255 | 254 |
$(root)/map $(+maps) |
256 |
map2db = env out_database=vegbien $(map) |
|
255 |
map2db = $(if $(use_staged),env in_database=vegbien in_schema=$(datasrc)\ |
|
256 |
in_table=$*) env out_database=vegbien $(map) |
|
257 | 257 |
|
258 | 258 |
##### Import to VegBIEN |
259 | 259 |
|
Also available in: Unified diff
input.Makefile: Mapping: $(map): Fixed bug where use_staged was causing in_schema, in_database, etc. to be set even when not outputting to vegbien, causing bin/map to try to output to a DB when it should output to stdout, by moving the use_staged test to $(map2db)