Coder Social home page Coder Social logo

lasertag's Introduction

Lasertag

Gem Version Build Status

Like most VCSs, Git has the ability to tag specific points in history as being important. Typically people use this functionality to mark release points (v1.0.0, and so on)

Usage

This will extract the android's app module version and create a matching git tag.

$ lasertag --module [module_name]

A bit more complex usage:

$ lasertag --path ~/Project --module app --flavor prod --remote origin

Handy in

Pretty handy in situations like the most used git workflow, the Gitflow Workflow, a strict branching model designed around the project release:

Full usage

Usage: lasertag [OPTIONS]

Options
  -m, --module MODULE    # Specifies the app module
  -f, --flavor FLAVOR    # Specifies the flavor (e.g. dev, qa, prod)
  -p, --path PATH        # Custom path to android project
  -d, --dont-push        # Only tags the code, doesn't push it upstream
  -r, --remote REMOTE    # Custom remote to your project (default: "origin")
  -h, --help             # Displays help
  -v, --version          # Displays version

Installation

$ gem install lasertag

Ubuntu

This tool requires a working Gradle distribution and currently does not make use of the Gradle wrapper bundled with the Android project. To install Gradle,

apt-get install gradle

This applies for other linux distros as well.

Under the hood

  • Tries to compile the project
  • Find out the package and the app version
  • executes git tag -a v[tag_version] -m "tag [tag_name]"
  • executes git push origin [tag_name]

Whenever a step fails, it stops the whole process and rolls it back.

License

The gem is available as open source under the terms of the MIT License.

lasertag's People

Contributors

cesarferreira avatar ragunathjawahar 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

Watchers

 avatar  avatar

lasertag's Issues

Unable to lasertag on Ubuntu

Hi, I have a new git repo. With just one commit. When I try to run lasertag on it,

sudo lasertag --path ./todoapp-mvp --module app -d

I get the following,

Something went wrong so I stopped all the madness!!

I am not sure which step has failed.

Update
Looks like it fails here...

def assemble_command
    "gradle :#{@app_module}:assemble#{(@app_flavor or "").capitalize}Release"
end

The script requires a gradle installation. Wouldn't it be nice to use the gradle wrapper gradlew available in the project for assembling? We could use gradlew by default and use gradle as a fallback. Which is very unlikely for most Android projects.

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.