Giter VIP home page Giter VIP logo

noteworx-cli-couchbase's Introduction

NoteWorx README

A basic note application that uses a CLI (Command Line Interface) frontend to capture and manage notes, and Couchbase Server as a data store.

Features

  • Add a note
  • Remove a note
  • Find notes by:
    • id
    • title
    • tag
  • List all notes
  • Tag a note
  • Update note

High Level Design

noteworx-cli-couchbase


Developed With

  • Node.js - Javascript runtime
  • yargs - Helps build CLI tools
  • Couchbase Server - Document database to store data
  • Docker - Used to host MongoDB instance (Not manadatory. See other options below)

Related Projects

  • noteworx-cli-fs

    A basic note application that uses a CLI (Command Line Interface) frontend to capture and manage notes, and a file system to store notes

  • noteworx-cli-mongodb

    A basic note application that uses a CLI (Command Line Interface) frontend to capture and manage notes, and mongodb to store notes

  • noteworx-cli-mongoose

    A basic note application that uses a CLI (Command Line Interface) frontend to capture and manage notes, Mongoose ODM to manage MongoDB interaction, and mongodb to store notes

  • noteworx-cli-express-mongodb

    A basic note application that uses a CLI (Command Line Interface) frontend to capture and manage notes, an express note management API built using Express, and Mongodb to store notes

  • noteworx-expressui-mongodb

    A basic note application that uses an Express frontend to capture and manage notes, and mongodb to store notes

  • noteworx-react-mongodb

    A basic note application that uses React frontend to capture and manage notes, an api written in ExpressJS, and mongodb to store notes


Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

The following software is required to be installed on your system:

  • NodeJS

    The following version of Node and Npm are required:

    • Node 8.x
    • Npm 3.x

    Type the following commands in the terminal to verify your node and npm versions

    node -v
    npm -v
  • Couchbase Server

    Couchbase Server 5.x is required

    Type the following address into your browser to verify that Couchbase Server is running on your local machine

    http://localhost:8091

    See alternative Couchbase Server hosting options below

Couchbase Server Setup

One of the 3 options below is recommended to get up and running with MongoDB:

  • Install and host locally
  • Install and host in container
  • Host in the cloud

Install And Host Locally

Visit the Couchbase Developer Portal for instructions on installing Couchbase Server on your OS.

Install And Host In Container

To host couchbase in a Docker container, type the following in your terminal:

docker run -d --name cb-dev -p 8091-8094:8091-8094 -p 11210:11210 couchbase

Next, open http://localhost:8091 in your browser

For more information, see Couchbase Server Docker Hub and Couchbase Containers

Host In The Cloud

Couchbase is available via the following cloud hosting providers:

Prepare Couchbase Server For NoteWorx

Once you have a Couchbase Server running, please visit these instructions on creating a Bucket. You will need to create a Bucket called 'noteworx' using all the default settings.

Once you have created the 'noteworx' Bucket, open the Query window and type the following command into the query editor:

CREATE PRIMARY INDEX `id-index` ON `noteworx` USING GSI;

At this point you have completed all that is required on the Couchbase Server for the application to work.

Install

Follow the following steps to get development environment running.

  1. Clone 'noteworx-cli-couchbase' repository from GitHub

    git clone https://github.com/drminnaar/noteworx-cli-couchbase.git

    or using ssh

    git clone [email protected]:drminnaar/noteworx-cli-couchbase.git
  2. Install node modules

    cd noteworx-cli-couchbase
    npm install

Run ESlint

  • Lint project using ESLint

    npm run lint
  • Lint project using ESLint, and autofix

    npm run lint:fix

Run

  • Run start

    This will run node app --help and show a list of CLI commands that can be used to manage notes

    npm start
  • Get help

    node app --help
    node app add --help
    node app remove --help
    node app find --help
    node app list --help
    node app tag --help
    node app update --help
  • Add a note

    node app add -t "Programming homework for weekend" -c "Read 'The Art of Computer Programming, Volume 1" --tags "programming, homework"
    node app add -t "Programming homework for today" -c "Read 'Computer Science Illuminated" --tags 'homework'
  • Remove a note

    node app remove --id "{NOTE_ID_GOES_HERE}"
  • Find notes

    • Find notes by title

      node app find -t "homework"
    • Find notes by id

      node app find --id "{NOTE_ID_GOES_HERE}"
    • Find notes by tag

      node app find --tag "programming"
  • List all notes

    node app list
  • Tag a note

    node app tag --id "{NOTE_ID_GOES_HERE}" --tag "{TAG_NAME_GOES_HERE}"
  • Update a note

    node app update --id "{NOTE_ID_GOES_HERE}" -t "Programming homework for weekend" -c "Read 'Computer Science Illuminated Pages 200-500" --tags "homework, compsci"

Versioning

I use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

noteworx-cli-couchbase's People

Contributors

drminnaar avatar

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.