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

Better factored workflow #2

Open
4 tasks
rufuspollock opened this issue Jan 18, 2014 · 0 comments
Open
4 tasks

Better factored workflow #2

rufuspollock opened this issue Jan 18, 2014 · 0 comments

Comments

@rufuspollock
Copy link
Contributor

Current issues:

  • No way to do post processing of information
  • Pre-processing is wrapped up in prompting and is sort of hacky
  • loading and writing of datapackage.json is not separate from the creation of datapackage.json

Proposal

Steps we need to perform (not necessarily in order)

  • Generate defaults (possibly given a directory)
  • Definition of things to ask (interactive)
    • Use current values (defaults or load of current dp.json)
      • initial values (given directory or some other info)
    • Output: array of questions [ ... ]
  • Post-processing (e.g. analyse urls to look at it)
    • dp.json plus some context (e.g. path to the directory, data files to add ...)
  • Final confirmation and write of the file (e.g. to disk)
    • This is probably outside of this library

In more complex scenario would loop steps 2 + 3 (e.g. answer to one item, would result in post-processing (e.g. analysis of data file that could alter what we ask ...)

Note: simplest possible right now would just be to have defaults function (ignore prompting etc etc ...)

Use cases

  • Create - no datapackage.json exists
  • Update existing datapackage.json
    • should we add defaults ??
    • specifically to add data resources
rufuspollock added a commit that referenced this issue Jan 18, 2014
* new defaults methods to generate default values
* use these from init method
* prompt.js is now obsolete and removed (and also dependency on init-package-json)
@roll roll removed the backlog label Aug 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants