Giter VIP home page Giter VIP logo

vim-pants's Introduction

Overview

A vim plugin for Pants build tool.

The core utility provided is the Pants command. Invoke it like so

:Pants [goal] [target] ...

The default goal is "compile". The default target is inferred from the current file's parent BUILD file.

When run with one argument, replace the default goal with the given argument. When run with two arguments, replace the default goal with the first argument, and default target with the second argument. The target syntax is described here; you can use '.' as an alias for the default target (see the example below). When run with more than two arguments, set the goal and target as described above using the first two arguments, and pass the remaining arguments to Pants.

Errors and warnings will be loaded in a quickfix list once Pants finishes running.

Uses vim-dispatch if present. This is highly recommended (along with tmux) to avoid blocking the entire editor when Pants runs.

Additionally, a convenience command, :Junit, is provided to run the current file as a JUnit test suite (only if file ends with Test.scala or Spec.scala).

Examples

Compile the default target; its sources will include the current file:

:Pants

Run the tests in foobird target (from project root)

:Pants test foobird:tests

Start a new REPL (especially useful as a split window if vim-dispatch is used) using the classpath of the default target:

:Pants repl

Compile a different target within the parent BUILD file ("foo") instead of using the default target (the target matching the parent directory's name). Also pass some additional arguments to Pants.

:Pants compile .:foo -arg1 -arg2

Run current file as JUnit test suite:

:Junit

vim-pants's People

Contributors

edma2 avatar mjeffryes avatar

Watchers

 avatar  avatar  avatar

Forkers

objmagic

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.