Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Make"-like facility in AMI #57

Open
petermr opened this issue May 25, 2020 · 0 comments
Open

"Make"-like facility in AMI #57

petermr opened this issue May 25, 2020 · 0 comments

Comments

@petermr
Copy link
Owner

petermr commented May 25, 2020

ami operates over a CProject (or a list of CTrees which are often only partially processed. This could be because:

  • new CTrees have been downloaded
  • processing was interrupted (crash, timeout)

It's useful to be able to skip the items already processed, especially as some processes can take seconds or even longer. Skipping is not trivial as the dependencies may be complex but we can give some simple rules. At present we have a facility CMFileUtil.shouldMake

		File svgDir = this.getExistingSVGDir();
		if (svgDir != null && !CMFileUtil.shouldMake(forceMake, svgDir, existingFulltextPDF)) {
			System.out.print("make skipped ");
			return false;
		}

Read as "

build if (forceMake or svgDir is missing or svgDir is olderThan existingFulltextPDF)

This has been implemented in several subcommands. However it's hardcoded and would be much better declaratively and perhaps linked to the @Command itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant