├── .gitignore ├── .npmrc ├── LICENSE ├── README.md ├── bin ├── card.mjs └── output ├── biome.json ├── build.mjs └── package.json /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | 8 | # Runtime data 9 | pids 10 | *.pid 11 | *.seed 12 | *.pid.lock 13 | 14 | # Directory for instrumented libs generated by jscoverage/JSCover 15 | lib-cov 16 | 17 | # Coverage directory used by tools like istanbul 18 | coverage 19 | 20 | # nyc test coverage 21 | .nyc_output 22 | 23 | # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) 24 | .grunt 25 | 26 | # Bower dependency directory (https://bower.io/) 27 | bower_components 28 | 29 | # node-waf configuration 30 | .lock-wscript 31 | 32 | # Compiled binary addons (https://nodejs.org/api/addons.html) 33 | build/Release 34 | 35 | # Dependency directories 36 | node_modules/ 37 | jspm_packages/ 38 | 39 | # TypeScript v1 declaration files 40 | typings/ 41 | 42 | # Optional npm cache directory 43 | .npm 44 | 45 | # Optional eslint cache 46 | .eslintcache 47 | 48 | # Optional REPL history 49 | .node_repl_history 50 | 51 | # Output of 'npm pack' 52 | *.tgz 53 | 54 | # Yarn Integrity file 55 | .yarn-integrity 56 | 57 | # dotenv environment variables file 58 | .env 59 | 60 | # parcel-bundler cache (https://parceljs.org/) 61 | .cache 62 | 63 | # next.js build output 64 | .next 65 | 66 | # nuxt.js build output 67 | .nuxt 68 | 69 | # vuepress build output 70 | .vuepress/dist 71 | 72 | # Serverless directories 73 | .serverless 74 | 75 | # FuseBox cache 76 | .fusebox/ 77 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | package-lock=false -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Tierney Cyren 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | It's me, Tierney! 2 | 3 | # Usage 4 | 5 | ## npm 6 | ``` 7 | npx bitandbang 8 | ``` 9 | 10 | ## GitHub Package Registry 11 | Assuming you have the GitHub registry set up, you can use via npx: 12 | ``` 13 | npx @bnb/card 14 | ``` 15 | 16 | Not including how to use it globally because I'm not sure why you'd want this as a global command. That'd be creepy. 17 | -------------------------------------------------------------------------------- /bin/card.mjs: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | // 👆 Used to tell Node.js that this is a CLI tool 3 | 4 | import { readFileSync } from 'node:fs'; 5 | import { join } from 'node:path'; 6 | 7 | const output = readFileSync(join(import.meta.dirname, 'output'), 'utf8'); 8 | console.log(output); 9 | -------------------------------------------------------------------------------- /bin/output: -------------------------------------------------------------------------------- 1 |  2 |  ╭────────────────────────────────────────────────────────────╮ 3 |  │ │ 4 |  │  Tierney Cyren / bitandbang / bnb │ 5 |  │ │ 6 |  │  Work: Principal Developer Advocate at Twilio (::) │ 7 |  │  Twitter: https://twitter.com/bitandbang │ 8 |  │ Mastodon: https://mastodon.social/@bnb │ 9 |  │  npm: https://npmjs.com/~bnb │ 10 |  │  GitHub: https://github.com/bnb │ 11 |  │ LinkedIn: https://linkedin.com/in/bitandbang │ 12 |  │  Web: https://bnb.im │ 13 |  │ │ 14 |  │  Card: npx bitandbang │ 15 |  │ │ 16 |  ╰────────────────────────────────────────────────────────────╯ 17 |  -------------------------------------------------------------------------------- /biome.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://biomejs.dev/schemas/1.6.1/schema.json", 3 | "organizeImports": { 4 | "enabled": true 5 | }, 6 | "javascript": { 7 | "formatter": { 8 | "quoteStyle": "single" 9 | } 10 | }, 11 | "linter": { 12 | "enabled": true, 13 | "rules": { 14 | "recommended": true 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /build.mjs: -------------------------------------------------------------------------------- 1 | // Pull in our modules 2 | import chalk from 'chalk'; 3 | import boxen from 'boxen'; 4 | import { writeFileSync } from 'node:fs'; 5 | import { join } from 'node:path'; 6 | 7 | // Define options for Boxen 8 | const options = { 9 | padding: 1, 10 | margin: 1, 11 | borderStyle: 'round', 12 | }; 13 | 14 | // Text + chalk definitions 15 | const data = { 16 | name: chalk.white(' Tierney Cyren'), 17 | handle: chalk.white('bitandbang'), 18 | shorthandle: chalk.white('bnb'), 19 | work: chalk.white('Principal Developer Advocate at Twilio (::)'), 20 | twitter: chalk.gray('https://twitter.com/') + chalk.cyan('bitandbang'), 21 | mastodon: chalk.gray('https://mastodon.social/') + chalk.magenta('@bnb'), 22 | npm: chalk.gray('https://npmjs.com/') + chalk.red('~bnb'), 23 | github: chalk.gray('https://github.com/') + chalk.green('bnb'), 24 | linkedin: chalk.gray('https://linkedin.com/in/') + chalk.blue('bitandbang'), 25 | web: chalk.cyan('https://bnb.im'), 26 | npx: `${chalk.red('npx')} ${chalk.white('bitandbang')}`, 27 | labelWork: chalk.white.bold(' Work:'), 28 | labelTwitter: chalk.white.bold(' Twitter:'), 29 | labelMastodon: chalk.white.bold('Mastodon:'), 30 | labelnpm: chalk.white.bold(' npm:'), 31 | labelGitHub: chalk.white.bold(' GitHub:'), 32 | labelLinkedIn: chalk.white.bold('LinkedIn:'), 33 | labelWeb: chalk.white.bold(' Web:'), 34 | labelCard: chalk.white.bold(' Card:'), 35 | }; 36 | 37 | // Actual strings we're going to output 38 | const newline = '\n'; 39 | const heading = `${data.name} / ${data.handle} / ${data.shorthandle}`; 40 | const working = `${data.labelWork} ${data.work}`; 41 | const twittering = `${data.labelTwitter} ${data.twitter}`; 42 | const mastodoning = `${data.labelMastodon} ${data.mastodon}`; 43 | const npming = `${data.labelnpm} ${data.npm}`; 44 | const githubing = `${data.labelGitHub} ${data.github}`; 45 | const linkedining = `${data.labelLinkedIn} ${data.linkedin}`; 46 | const webing = `${data.labelWeb} ${data.web}`; 47 | const carding = `${data.labelCard} ${data.npx}`; 48 | 49 | // Put all our output together into a single variable so we can use boxen effectively 50 | const output = 51 | heading + // data.name + data.handle 52 | newline + 53 | newline + // Add one whole blank line 54 | working + 55 | newline + // data.labelWork + data.work 56 | twittering + 57 | newline + // data.labelTwitter + data.twitter 58 | mastodoning + 59 | newline + // data.labelTwitter + data.twitter 60 | npming + 61 | newline + // data.labelnpm + data.npm 62 | githubing + 63 | newline + // data.labelGitHub + data.github 64 | linkedining + 65 | newline + // data.labelLinkedIn + data.linkedin 66 | webing + 67 | newline + 68 | newline + // data.labelWeb + data.web 69 | carding; // data.labelCard + data.npx 70 | 71 | writeFileSync( 72 | join(import.meta.dirname, 'bin/output'), 73 | chalk.green(boxen(output, options)), 74 | ); 75 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "bitandbang", 3 | "version": "4.0.1", 4 | "description": "A personal card for Tierney Cyren (@bitandbang)", 5 | "main": "/bin/card.mjs", 6 | "bin": { 7 | "bitandbang": "./bin/card.mjs" 8 | }, 9 | "repository": { 10 | "type": "git", 11 | "url": "git+https://github.com/bnb/bitandbang.git" 12 | }, 13 | "homepage": "https://bnb.im", 14 | "scripts": { 15 | "prepublish": "npm run build", 16 | "build": "node build.mjs", 17 | "dev": "npm run build && node ./bin/card.mjs", 18 | "format": "npx @biomejs/biome format --write", 19 | "lint": "npx @biomejs/biome lint --write", 20 | "check": "npx @biomejs/biome check --write" 21 | }, 22 | "keywords": [ 23 | "card", 24 | "npm", 25 | "npm card", 26 | "npx", 27 | "npx card", 28 | "business card" 29 | ], 30 | "author": "Tierney Cyren (http://bnb.im)", 31 | "license": "MIT", 32 | "files": [ 33 | "bin/card.mjs", 34 | "bin/output" 35 | ], 36 | "devDependencies": { 37 | "@biomejs/biome": "1.8.2", 38 | "boxen": "^7.1.1", 39 | "chalk": "^5.3.0" 40 | }, 41 | "bugs": { 42 | "url": "https://github.com/bnb/bitandbang/issues" 43 | } 44 | } 45 | --------------------------------------------------------------------------------