Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/emgyrz/tagger
https://github.com/emgyrz/tagger
Last synced: 8 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/emgyrz/tagger
- Owner: emgyrz
- License: mit
- Created: 2019-06-10T21:53:11.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-06-06T21:38:06.000Z (over 2 years ago)
- Last Synced: 2024-04-29T06:22:34.777Z (9 months ago)
- Language: Rust
- Size: 36.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# tagger
[![npm](https://img.shields.io/npm/v/tagger-bin.svg)](https://www.npmjs.com/package/tagger-bin)
Simple utility to do something (e.g. install) packages from git repository by selecting git tag which is presented by semver rules.
Tagger works with git repositories only through ssh connection.
If you have a package that is not in npm or local repos but it has versionong, `tagger` may be helpful for you.
### Requirements
`tagger` works with:
- ~~macOS~~ `// TODO`
- Linux (64-bit)
- Windows (64-bit)### CLI
```
Usage: tagger (--help | --version)
tagger [--cfg PATH] (--show-latest | --list-all) PACKAGES...
tagger [--exec --cfg PATH] PACKAGES...Options:
-h, --help Show this message.
-v, --version Show the version of tagger.
-c PATH, --cfg PATH Path to config file. If not specified config will be searching in ./.tagger.cfg.json and ~/.tagger.cfg.json"
-l, --show-latest Prints latest valid tag.
-a, --list-all Prints all valid by semver tags.
-e, --exec *optional. Do something with specified or latest package version.Examples:
tagger ui
tagger --show-latest hlp
tagger --exec -c ../path_to_tagger_config.json [email protected]
```### Config file
Config file name by default is `.tagger.cfg.json`. And if it is not specified, it is searched in directory where you run `tagger` or in your home directory (e.g. `~/.tagger.cfg.json`).Config includes fields:
#### `repos`
Type: `Array<{name: string, url: string}>`List of package repositories you want to use. Each item in this list cantains `name` ( to identify it )
and `url` know how to connect.
Example:
```json
{
"repos": [
{
"name": "tagger",
"url": "ssh://[email protected]:emgyrz/tagger.git"
}
],
// ...
}
```#### `command`
Type: `String`Says what to do with package. In `command` you have several variables that will be replaced on executing
- `{NAME}` - name of package presents in repo
- `{URL}` - same
- `{VERSION}` - version of package you were specify or latest versionExample:
```js
{
// ...
"command": "yarn add {URL}#{VERSION}"
// "command": "echo 'my latest version of package {NAME} is {VERSION}'",
// "command": "rm -rf / :)"
}
```##### Enjoy using!
### License
This package is [MIT licensed](./LICENSE).