Git Product home page Git Product logo

bashme's Introduction

bashme

Bashme is a library which provides a nerdy way to tell people about you. It was created with the intention to use it as a resumé replacement but I it can have other use cases. It aims to be customizable, extensible and easy to use.

Demo

Play with it in my personal website: http://agurodriguez.net

Getting Started

Install it:

npm install bashme

Use it:

var bashme = new Bashme.Bashme();
bashme.use(new Bashme.GitHub('agurodriguez'));
bashme.show(document.querySelector('#bashme'));

Full code in example folder.

If you use react, you can try react-bashme.

A bit into the code

The Bashme instance

Bashme is the main class which acts as library's entry point. It's reponsible for processing the input/output from/to the terminal and for running the tasks related to every given command.

It has two important methods, use and show:

use(provider: IProvider)

This method registers a new IProvider in the Bashme instance. When the IProvider is registerd it adds commands to the Bashme instance that can be called by the user.

show(domElement: HTMLElement)

This method converts an HTMLElement into a full interactive terminal (Using xterm.js) to allow users to write the commands they want to execute.

Providers

A provider is a class that implements the IProvider interface and provides commands to the Bashme instance that the user can then execute.

Commands

A command is a class that inhertis from the AsyncCommand or the SyncCommand classes and are used to perform some specific action.

Built-in Providers

GitHub

See GitHub.ts

Commands

Command Description
github Shows GitHub profile information
github contribs Shows GitHub contributions
github orgs Shows GitHub organizations
github repos Shows GitHub repositories

Json

See Json.ts

Commands

Command Description
name Shows name
bio Shows bio
education Shows education
work Shows work experience
volunteer Shows volunteer experience
awards Shows awards
publications Shows publications
skills Shows skills
languages Shows languages

License

MIT License

Copyright (c) 2018 Agustín Rodríguez

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

bashme's People

Contributors

dependabot[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

bashme's Issues

Interface doesn't work correctly on mobile device

Tested on Google Pixel. Browser is Chrome with latest update.
Interface loads correctly. If I enter an unrecognized command, I get an error message (as expected)

If I enter any valid command (i.e. skills) and press enter, I get a new system prompt in a newline, with the previous command already visible, but the command output isn't retrieved and displayed on my screen.

Oddly enough, when taking screenshots (see link below), the command isnt visible.

Everything works correctly on my Windows laptop.

http://photos.app.goo.gl/hrKGvBzjnvj7rnay5

Backspace not working in CLI

Pressing backspace on Version 70.0.3538.110 (Official Build) (64-bit) is not currently working.

Tested on your personal site @agurodriguez ,

Will build and test locally.

(Awesome interface though by the way! love the project)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.