GitXplorerGitXplorer
d

bento

public
0 stars
9 forks
0 issues

Commits

List of commits on branch master.
Verified
f3abfcb4062cf82c4306dcfd0601a5afaf34fc6e

Merge pull request #125 from returntocorp/beta_guidelines_2

ddaghan committed 5 years ago
Unverified
12d4df4c564f0e1b572641f3691b0f83b998f1d5

missed installation

ddaghan committed 5 years ago
Verified
9f7ad4ddd9b3293c1508ba50dcbcc22acb2ba603

Merge pull request #123 from returntocorp/beta_guidelines

ddaghan committed 5 years ago
Unverified
ab6e31fa1e3b51a4bbc7b98fc172cf5d12f98419

fixed pre merge

ddaghan committed 5 years ago
Unverified
b6eaa2feab78d2c8dfba74471c6966a2b543f7c0

fixed pre merge

ddaghan committed 5 years ago
Unverified
3b8595cb1f76ec91806acdf3bf04a2a3cd4a3eaa

fixed pre merge

ddaghan committed 5 years ago

README

The README file for this repository.

Bento

Bento automatically tailors linters and static analysis with sane defaults on a per-project basis, letting you focus on writing code rather than configuring tools. Bento is free, fully-featured, and you can run Bento on as many projects as you like.

Installation

Requirements

Bento is supported on macOS Mojave (10.14) and Ubuntu 18.04+, and requires Python 3.6 or later, and pip3.

Bento supports npm-packaged JavaScript and Python, and is ideal for monorepos.

To run Bento on projects that include JavaScript, Node.js is required and the following versions are supported:

  • Node.js 8 (8.10.0 and above)
  • Node.js 10 (10.13.0 and above)
  • Anything above Node.js 11.10.1

Installing Bento

Bento is a command-line tool that is simple to install:

pip3 install bento-cli

Usage

The workflow for Bento is:

  1. Initialize Bento
  2. Run Bento checks on your source code
  3. Fix issues or archive unnecessary warning and errors
  4. Disable undesired checks
  5. Add Bento to git pre-commit hooks
  6. Add Bento to the CI pipeline (e.g., CircleCI)

Initialize Bento for a project:

In your project directory, run:

bento init

and add some of the artifacts bento produces to your .gitignore file:

printf "# Bento tools:\n.bento/" >> .gitignore

Analyze your source code

To trigger Bento to analyze your project, run:

bento check

Archive outstanding issues

The archive command whitelists outstanding issues to fix later. This lets you continue coding with a clean slate without having to address all your tech debt as soon as you adopt a new tool. New issues introduced from this point forward will be reported by Bento until the next time you run the archive command.

Archive issues by running:

bento archive

Disable and enable individual checks

Enable/disable a specific check by running:

bento enable [OPTIONS] TOOL CHECK

or

bento disable [OPTIONS] TOOL CHECK

where:

  • TOOL refers to the tool that includes the check, for example, r2c.eslint
  • CHECK refers to the label for the check you want to enable, for example no-console

Example:

bento enable r2c.eslint no-console

You can find the tool and check names in the output of bento check. Bento currently supports the following tools:

Language Supported Tools
Python Bandit, Flake8
JavaScript ESLint

If there are tools you'd like us to add, please let us know by creating an issue.

Install Bento as a pre-commit hook

Bento can install itself as a pre-commit hook, so it runs before each commit and blocks on failures.

To install bento as a pre-commit hook, simply run:

bento install-hook

Demo

Here’s a short preview of Bento in action:

Bento demo

Community

Join the Bento channel in our community Slack to receive and give support, talk with other users, and share things about Bento. The r2c team is there and ready to help!

Terms of service and privacy

Please refer to the terms and privacy document.

License

Copyright (c) r2c.

r2c logo