farm-invest-cli
Advanced tools
Comparing version 1.0.2 to 1.0.3
{ | ||
"name": "farm-invest-cli", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Are there new investment opportunities on FarmCrowdy, ThriveAgric or EFarms?", | ||
@@ -5,0 +5,0 @@ "main": "src/farm-invest-cli.js", |
@@ -5,2 +5,3 @@ # Farm Invest CLI | ||
- [AgroPartnerships](https://agropartnerships.co) | ||
- [EFarms](https://www.efarms.com.ng) | ||
@@ -37,2 +38,3 @@ - [ThriveAgric](https://www.thriveagric.com) | ||
farm-invest-cli | ||
farm-invest-cli agro # only agro-partnerships | ||
farm-invest-cli efarms # only efarms | ||
@@ -52,3 +54,3 @@ farm-invest-cli farm-crowdy # only farm-crowdy | ||
```js | ||
const { syncAll, syncEFarms, syncFarmCrowdy, syncThriveAgric } = require('farm-invest-cli') | ||
const { syncAll, syncAgro, syncEFarms, syncFarmCrowdy, syncThriveAgric } = require('farm-invest-cli') | ||
@@ -59,2 +61,6 @@ syncAll().then(diff => { | ||
syncAgro().then(diff => { | ||
console.log(diff.toString()) // a product text diff for Agro-Partnerships | ||
}) | ||
syncEFarms().then(diff => { | ||
@@ -74,4 +80,8 @@ console.log(diff.toString()) // a product text diff for eFarms | ||
```js | ||
const { getEFarms, getFarmCrowdy, getThriveAgric } = require('farm-invest-cli') | ||
const { getAgro, getEFarms, getFarmCrowdy, getThriveAgric } = require('farm-invest-cli') | ||
getAgro().then(productListText => { | ||
console.log(productListText) // a textual description of active products on Agro-Partnerships | ||
}) | ||
getEFarms().then(productListText => { | ||
@@ -78,0 +88,0 @@ console.log(productListText) // a textual description of active products on eFarms |
@@ -0,1 +1,2 @@ | ||
const getAgro = require('./sites/agro') | ||
const getEFarms = require('./sites/efarms') | ||
@@ -8,2 +9,3 @@ const getFarmCrowdy = require('./sites/farm-crowdy') | ||
try { | ||
const syncAgro = require('./farm-invest-cli-agro') | ||
const syncEFarms = require('./farm-invest-cli-efarms') | ||
@@ -14,2 +16,3 @@ const syncFarmCrowdy = require('./farm-invest-cli-farm-crowdy') | ||
return await Promise.all([ | ||
syncAgro({ getAgro, fs }), | ||
syncEFarms({ getEFarms, fs }), | ||
@@ -16,0 +19,0 @@ syncFarmCrowdy({ getFarmCrowdy, fs }), |
#!/usr/bin/env node | ||
const getAgro = require('./sites/agro') | ||
const getEFarms = require('./sites/efarms') | ||
@@ -7,2 +8,3 @@ const getFarmCrowdy = require('./sites/farm-crowdy') | ||
const syncAll = require('./farm-invest-cli-all') | ||
const syncAgro = require('./farm-invest-cli-agro') | ||
const syncEFarms = require('./farm-invest-cli-efarms') | ||
@@ -18,2 +20,3 @@ const syncFarmCrowdy = require('./farm-invest-cli-farm-crowdy') | ||
.version(pjson.version) | ||
.command('agro [env]', 'shows latest info on agro partnerships') | ||
.command('efarms [env]', 'shows latest info on efarms') | ||
@@ -26,2 +29,3 @@ .command('farm-crowdy [env]', 'shows latest info on farm-crowdy') | ||
module.exports.getAgro = getAgro | ||
module.exports.getEFarms = getEFarms | ||
@@ -31,4 +35,5 @@ module.exports.getFarmCrowdy = getFarmCrowdy | ||
module.exports.syncAll = syncAll | ||
module.exports.syncAgro = syncAgro | ||
module.exports.syncEFarms = syncEFarms | ||
module.exports.syncFarmCrowdy = syncFarmCrowdy | ||
module.exports.syncThriveAgric = syncThriveAgric |
@@ -10,7 +10,9 @@ const fs = require('fs') | ||
module.exports.filesDir = filesDir | ||
module.exports.agroHtml = path.join(filesDir, 'agro.html') | ||
module.exports.eFarmsHtml = path.join(filesDir, 'efarms.html') | ||
module.exports.farmCrowdyHtml = path.join(filesDir, 'farm-crowdy.html') | ||
module.exports.thriveAgricHtml = path.join(filesDir, 'thrive-agric.html') | ||
module.exports.agroTxt = path.join(filesDir, 'agro.txt') | ||
module.exports.eFarmsTxt = path.join(filesDir, 'efarms.txt') | ||
module.exports.farmCrowdyTxt = path.join(filesDir, 'farm-crowdy.txt') | ||
module.exports.thriveAgricTxt = path.join(filesDir, 'thrive-agric.txt') |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
37503
20
396
93
11