Skip to content

Commit

Permalink
Merge pull request #3 from EyeSeeTea/development
Browse files Browse the repository at this point in the history
Release 0.0.1
  • Loading branch information
adrianq authored Feb 13, 2019
2 parents dab788b + 54d8e01 commit cae04cf
Show file tree
Hide file tree
Showing 10 changed files with 2,443 additions and 1 deletion.
34 changes: 34 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"env": {
"browser": true,
"es6": true
},
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": 2015,
"sourceType": "module"
},
"rules": {
"indent": [
"error",
4
],
"linebreak-style": [
"error",
"unix"
],
"quotes": [
"error",
"double"
],
"semi": [
"error",
"always"
],
"no-unused-vars": [
"error",
{"args": "all", "argsIgnorePattern": "^_"}
],
"array-bracket-spacing": ["error", "never"]
}
}
62 changes: 62 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Logs
logs
bak
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# next.js build output
.next
20 changes: 19 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,19 @@
# vaccination-metadata
Setup metadata to use Vaccination App in a DHIS2 instance.

## Generate metadata

```
$ node src/cli.js generate --url='http://admin:district@localhost:8080' -i source-data.json -o metadata.json
```

This will generate metadata prepared for a specific DHIS2 instance, so objects will be re-used if existing (uses field `name` as key).

## Post metadata

Once the metadata is generated, you can send it the same DHIS2 instance:

```
$ node src/cli.js post --url='http://admin:district@localhost:8080' -i metadata.json
```

Records will be created or updated as necessary. This command may be run many times, no duplicates should be created.
23 changes: 23 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"name": "vaccination-metadata",
"version": "1.0.0",
"main": "index.js",
"repository": "https://github.com/EyeSeeTea/vaccination-metadata",
"author": "[email protected]",
"license": "MIT",
"scripts": {
"lint": "eslint src"
},
"dependencies": {
"argparse": "^1.0.10",
"lodash": "^4.17.11",
"md5": "^2.2.1",
"node-fetch": "^2.3.0",
"p-map": "^2.0.0"
},
"devDependencies": {
"babel-eslint": "^10.0.1",
"eslint": "^5.10.0",
"eslint-plugin-react": "^7.11.1"
}
}
Loading

0 comments on commit cae04cf

Please sign in to comment.