Project

General

Profile

« Previous | Next » 

Revision 5457

Makefile, input.Makefile: Use new $(version), which unlike $(date) also includes the svn revision, to version log files, etc. This way, the working copy can be put back to the way it was at the time of a given import (excluding changes to nonversioned files). This also makes it easier to get all the log files for a particular import when different tables' imports started at different times.

View differences:

input.Makefile
315 315
profileOnly = -env profile_to=/dev/fd/3 $(map2db) 3>&1 1>&2|\
316 316
$(bin)/profile_stats /dev/fd/0
317 317

  
318
log_ = $*/logs/$(if $(n),n=$(n).,)$(date).log.sql
318
log_ = $*/logs/$(if $(n),n=$(n).,)$(version).log.sql
319 319
trace = $(log_:.log.sql=.trace)
320 320
import = -$(if $(profileTest),$(profileOnly),(set -x; "time" env commit=1\
321 321
$(if $(profile),profile_to=$(trace)) $(map2db)) $(if $(log),\
......
366 366
##### Editing import
367 367

  
368 368
rotate: _always
369
	echo "UPDATE party SET organizationname = organizationname||'.$(date)'\
369
	echo "UPDATE party SET organizationname = organizationname||'.$(version)'\
370 370
WHERE organizationname = '$(datasrc)';"|$(psqlAsBien)
371 371

  
372 372
rm: _always

Also available in: Unified diff