Giter Site home page Giter Site logo

nakabonne / golintui Goto Github PK

View Code? Open in Web Editor NEW
80.0 4.0 4.0 9.93 MB

A simple terminal UI for Go linters

License: GNU General Public License v3.0

Go 99.62% Dockerfile 0.38%
go golang golang-tools golangci-lint linter static-analysis tui terminal

golintui's Introduction

golintui

License: GPL v3

golintui is a TUI tool that helps you run various kinds of linters with ease and organize its results, with the power of golangci-lint.

Screenshot

Cool features

  • Simple UI
  • Selectable linters on the UI.
  • Sorting out the issues for each linter
  • Able to open files by specifying the issue line

Installation

Binary Releases

For Mac OS or Linux, you can download a binary release here.

With Homebrew

brew install nakabonne/golintui/golintui

With Go

go get github.com/nakabonne/golintui

Note that go get downloads a bunch of dependencies on golangci-lint so can take a while to fully install.

With Docker

docker run --rm -i -t -v $(pwd):/app -w /app nakabonne/golintui:latest golintui

Usage

Requires: golangci-lint executable.

Be sure to change the CTYPE as shown below if your locale isn't en_US. The UI does not display well without it.

export LC_CTYPE=en_US.UTF-8

Quick Start

golintui

Just press r, then results from the linters should be shown.

Keybinds

Global

  r: run selected linters against the selected directories
  q: quit
  l: next panel
  h: previous panel
  j: move down
  k: move up

Linters Panel

  space: toggle enabled

Note that for users who specify disable-all in the config file for golangci-lint, it is impossible to disable linters that are enabled in it.

Source File Panel

  space: toggle selected
  o: expand directory

Commits Panel

  space: toggle selected

It shows only new issues created after the commit you selected. Internally it just gives it on to --new-from-rev.

Results Panel

  o: open a file with the reported line

Settings

Editor

golintui refers to $EDITOR by default to open the problematic file. You can change the editor to your taste and habits by setting $GOLINTUI_OPEN_COMMAND.

For instance, for users of VSCode:

export GOLINTUI_OPEN_COMMAND="code -r"

Editors that can open by specifying a line

  • vim(vi)
  • emacs
  • VSCode

Please let me know how to open a file at a specific line if the editor you're used to is missing.

License Scan

FOSSA Status

golintui's People

Contributors

nakabonne 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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

golintui's Issues

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.