Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/eventonehq/cordova-utils

💻 A set of basic utilities for Apache Cordova apps.
https://github.com/eventonehq/cordova-utils

cli cordova semver utility

Last synced: about 1 month ago
JSON representation

💻 A set of basic utilities for Apache Cordova apps.

Awesome Lists containing this project

README

        

# cordova-utils

[![Build Status](https://api.travis-ci.com/eventOneHQ/cordova-utils.svg?branch=master)](http://travis-ci.com/eventOneHQ/cordova-utils)
[![NPM Version](https://img.shields.io/npm/v/cordova-utils.svg?style=flat)](https://www.npmjs.org/package/cordova-utils)
[![NPM Downloads](https://img.shields.io/npm/dm/cordova-utils.svg?style=flat)](https://www.npmjs.org/package/cordova-utils)
[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

A set of basic utilities for Apache Cordova apps.

## Installing

```bash
npm install -g cordova-utils

# or if you just want to use it locally
npx cordova-utils version -v 1.4.5 -b 445
```

_Note: For a global install of `-g cordova-utils`, OSX/Linux users may need to prefix the command with `sudo` or can setup [proper file permissions on OSX for npm](http://www.johnpapa.net/how-to-use-npm-global-without-sudo-on-osx/) to install without `sudo`._

## Usage:

### Command Line

```bash
cordova-utils version [options] -v -b
```

**Example:**

```bash
cordova-utils version -v 1.4.5 -b 445
```

### Library

**Example:**

```javascript
// CJS
const CordovaUtils = require('cordova-utils')
// or MJS
import CordovaUtils from 'cordova-utils'

const cordovaUtils = new CordovaUtils()

cordovaUtils
.setVersion(version, build, configFile)
.then(res => {
// do something
})
.catch(err => {
// handle error
})
```