From 1c7fbe09b66f7095cbd357cfb6bc4fa7a9a6f2d0 Mon Sep 17 00:00:00 2001 From: Kaustubh Ladiya Date: Sun, 12 Jan 2020 15:55:54 +0530 Subject: [PATCH] Add support for Keybase --- .eslintrc.json | 33 ++++++++++++++++----------------- .prettierrc | 1 - .travis.yml | 1 + bin/gitfolio.js | 1 + build.js | 1 + package.json | 2 +- populate.js | 10 ++++++++++ ui.js | 2 ++ update.js | 1 + views/index.ejs | 8 ++++++++ 10 files changed, 41 insertions(+), 19 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index f1e3d15..d3fb99f 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,18 +1,17 @@ { - "env": { - "browser": true, - "es6": true, - "node": true - }, - "extends": "eslint:recommended", - "globals": { - "Atomics": "readonly", - "SharedArrayBuffer": "readonly" - }, - "parserOptions": { - "ecmaVersion": 2018, - "sourceType": "module" - }, - "rules": { - } -} \ No newline at end of file + "env": { + "browser": true, + "es6": true, + "node": true + }, + "extends": "eslint:recommended", + "globals": { + "Atomics": "readonly", + "SharedArrayBuffer": "readonly" + }, + "parserOptions": { + "ecmaVersion": 2018, + "sourceType": "module" + }, + "rules": {} +} diff --git a/.prettierrc b/.prettierrc index 0d3edfc..dce3e9f 100644 --- a/.prettierrc +++ b/.prettierrc @@ -1,5 +1,4 @@ { - "singleQuote": false, "overrides": [ { "files": ["*.html", "*.ejs"], diff --git a/.travis.yml b/.travis.yml index 8ad8d42..63e5e86 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,6 +13,7 @@ before_script: - npm install -g script: - npm run test + - npm run prettier after_success: - lhci autorun --upload.target=temporary-public-storage --staticDistDir=/home/travis/build/k4ustu3h/gitfolio/dist deploy: diff --git a/bin/gitfolio.js b/bin/gitfolio.js index 58e41dc..39e5c92 100755 --- a/bin/gitfolio.js +++ b/bin/gitfolio.js @@ -31,6 +31,7 @@ program .option("-D, --dribbble [username]", "specify dribbble username") .option("-e, --email [username]", "specify email") .option("-i, --instagram [username]", "specify instagram username") + .option("-k, --keybase [username]", "specify keybase username") .option("-r, --reddit [username]", "specify reddit username") .option("-T, --telegram [username]", "specify telegram username") .option("-w, --twitter [username]", "specify twitter username") diff --git a/build.js b/build.js index 2ab8cda..c6e65b2 100644 --- a/build.js +++ b/build.js @@ -85,6 +85,7 @@ async function buildCommand(username, program) { dribbble: program.dribbble, email: program.email, instagram: program.instagram, + keybase: program.keybase, reddit: program.reddit, telegram: program.telegram, twitter: program.twitter diff --git a/package.json b/package.json index 0aff41f..bbbc82c 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "cli": "OUT_DIR='./dist' node bin/gitfolio.js", "clean": "rm -rf ./dist/*", "prettier": "prettier --write \"./**/*.{js,jsx,json,html,css,md}\"", - "test": "OUT_DIR='./dist' node bin/gitfolio.js build k4ustu3h --fork --theme dark --sort updated --twitter k4ustu3h_ --dribbble k4ustu3h --email k4ustu3h@gmail.com --codepen k4ustu3h --dev k4ustu3h --instagram k4ustu3h --telegram k4ustu3h --reddit kaustubhladiya" + "test": "OUT_DIR='./dist' node bin/gitfolio.js build k4ustu3h --fork --theme dark --sort updated --twitter k4ustu3h_ --dribbble k4ustu3h --email k4ustu3h@gmail.com --codepen k4ustu3h --dev k4ustu3h --instagram k4ustu3h --telegram k4ustu3h --reddit kaustubhladiya --keybase k4ustu3h" }, "author": { "name": "@imfunniee and community", diff --git a/populate.js b/populate.js index 7dbba3c..46a3003 100644 --- a/populate.js +++ b/populate.js @@ -38,6 +38,7 @@ module.exports.updateHTML = (username, opts) => { dribbble, email, instagram, + keybase, reddit, telegram, twitter @@ -156,6 +157,15 @@ module.exports.updateHTML = (username, opts) => { + + + + + diff --git a/ui.js b/ui.js index 0242ac9..525e809 100644 --- a/ui.js +++ b/ui.js @@ -58,6 +58,7 @@ function uiCommand() { const dribbble = req.body.dribbble ? req.body.dribbble : null; const email = req.body.email ? req.body.email : null; const instagram = req.body.instagram ? req.body.instagram : null; + const keybase = req.body.keybase ? req.body.keybase : null; const reddit = req.body.reddit ? req.body.reddit : null; const telegram = req.body.telegram ? req.body.telegram : null; const twitter = req.body.twitter ? req.body.twitter : null; @@ -75,6 +76,7 @@ function uiCommand() { dribbble, email, instagram, + keybase, reddit, telegram, twitter diff --git a/update.js b/update.js index e17140c..584df7d 100644 --- a/update.js +++ b/update.js @@ -21,6 +21,7 @@ async function updateCommand() { dribbble: data[0].dribbble, email: data[0].email, instagram: data[0].instagram, + keybase: data[0].keybase, reddit: data[0].reddit, telegram: data[0].telegram, twitter: data[0].twitter diff --git a/views/index.ejs b/views/index.ejs index 126d1c2..56c4d1d 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -146,6 +146,14 @@ name="instagram" />
+ +