• Stars
    star
    269
  • Rank 147,596 (Top 3 %)
  • Language
    Shell
  • License
    MIT License
  • Created over 10 years ago
  • Updated over 8 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Go Versioning Packager

Go Versioning Packager Build Status Support via Gratipay

gvp stands for Go Versioning Packager and is based on gst a similar tool that provides dependency isolation for Ruby gems.

The tool modifies your GOPATH to point to a local .godeps/ directory so that you can keep the dependencies of your project isolated there, it also modifies GOBIN and PATH to include the new GOPATH/bin directory.

gvp is a companion tool to gpm but both tools can be used independently from each other.

Example usage: Go Dependency Management and Vendoring with gpm + gvp:

gpm + gvp usage

Installation

Install in *nix (preferred method)

$ git clone https://github.com/pote/gvp.git && cd gvp
$ git checkout v0.2.1 # You can ignore this part if you want to install HEAD.
$ ./configure
$ make install

Install via Homebrew

$ brew install gvp

Usage

Since gvp is a script and runs in a child environment of your shell, the latter will not take the env changes unless you source them.

First,

$ source gvp

After gvp has been sourced, these commands are available:

usage: gvp [COMMAND]

[...]

COMMANDS
    source gvp      Modifies GOPATH and GOBIN to use the .godeps directory.
    gvp version     Outputs version information.
    gvp help        Prints this message.
    gvp in          The function that is called when executing "source gvp"
    gvp out         Return the prompt to normal

Using with autoenv

Simply run:

cd /path/to/project
touch .env
echo "source /path/to/gvp" > .env

Plugins

As of v0.1.0 gvp includes a plugin system very much similar to the one in gpm.

The way gvp plugin work is simple: whenever an unknown command is passed into gvp it will look for an executable in your $PATH called gvp- and if it exists it will run it while passing all extra arguments to it, simple yet powerful.

This brings a lot to the table: plugins can be written in anything, they can be Go binaries, bash scripts, Ruby gems, Python packages, you name it. gvp wants to make it easy for you to extend it. :)

If you happen to write a plugin for gvp: please open an issue so we can compile a list of useful plugins as well as add them to the gpm homebrew tap so users can install them easily.

Why?

Dependencies of multiple Go projects are by far easier to handle in isolation, using plain gpm to handle your dependencies means that you are forced to run it again every time you work on a new project, this can get old quickly.

Using gvp can greatly simplify your workflow, by isolating your Go project dependencies you only need to run source gvp in order to be back in the work environment of your application, this means that there will never be Go packages installed in your system which will conflict in versioning across your different projects.

If for some reason you need to ship your repository with its dependencies included this is also of help, but including a Godeps file to use with gpm will probably be your best option.

More Repositories

1

gpm

Barebones dependency manager for Go.
Shell
1,191
star
2

philote

Simple, topic-based PUB/SUB WebSocket server.
Go
181
star
3

disc

Simple Disque-powered Ruby Jobs
Ruby
129
star
4

planet.rb

A feed aggregator implementation intended to be used with Octopress
Ruby
66
star
5

hashifiable

Dead simple hash representation declarations.
Ruby
60
star
6

int

Tiny in-browser internationalization.
JavaScript
17
star
7

gohm

Go's Object Hash Mapper
Go
16
star
8

dropshare-landing

My dropshare landing page
JavaScript
12
star
9

gpm-bootstrap

A gpm plugin to kickstart your Go project's dependency versioning.
Shell
11
star
10

homebrew-gpm_plugins

A repository of gpm plugins installable through homebrew.
Ruby
8
star
11

box

A dead easy "inline filesystem" for your ruby scripts
Ruby
8
star
12

disco

An idiomatic Disque client for Go.
Go
7
star
13

dtb

Drinking Typing Bird
Go
5
star
14

philote-js

Browser library for the Philote websockets server
JavaScript
5
star
15

chronicler

A storytelling web toolkit for Go
Go
3
star
16

takeoff

Magically show your presentation's slides in a remote AppleTV or Computer running Airserver
JavaScript
3
star
17

gpm-all

A gpm plugin for per-environment dependency groups
Shell
3
star
18

philote-go

Go client for the Philote websocket server.
Go
2
star
19

wayfinder

A bookkeeping tool for the Pathfinder Role Playing Game.
Ruby
2
star
20

Planet

Code from planetplanet.org [I am not the author, but I needed to do some slight changes to it and decided to open a public repo for that]
Python
2
star
21

hashdot

Cozy Hash Accessors
Ruby
1
star
22

conference-resources

Resources for my conference-related things, talks, profile pictures, bio, etc.
1
star
23

Tamarindo

Time management for the attention span impaired
Python
1
star
24

kosmonaut

The backend protocol client for WebRocket
C
1
star
25

jane

A test CLI chat that uses Philote as it's backend.
Go
1
star
26

philote-chat-app

A stupid simple chat app intended to showcase the philote websocket server.
JavaScript
1
star
27

philote-rb

A Ruby client for the Philote websockets server.
Ruby
1
star
28

Fractions-of-Cakes

A math game for XO (OLPC) laptops
Python
1
star
29

jose-mujica-reddit-ama

We feel it would be super interesting to get Mr. Jose Mujica (Uruguay's current president) to do a reddit IAMA, this repo aims to be the official document with the proposal for him
1
star
30

Buena-Pregunta

Creative commons licensed music - complete or midway through - from my old band.
1
star