Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/windomz/url-generator
Generates URL address based on the directory.
https://github.com/windomz/url-generator
directory generator url url-generate
Last synced: 21 days ago
JSON representation
Generates URL address based on the directory.
- Host: GitHub
- URL: https://github.com/windomz/url-generator
- Owner: WindomZ
- License: mit
- Created: 2017-05-22T18:08:44.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2020-06-01T02:02:09.000Z (over 4 years ago)
- Last Synced: 2024-10-19T21:03:24.013Z (29 days ago)
- Topics: directory, generator, url, url-generate
- Language: JavaScript
- Homepage:
- Size: 1.99 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# url-generator
[![Greenkeeper badge](https://badges.greenkeeper.io/WindomZ/url-generator.svg)](https://greenkeeper.io/)
[![Build Status](https://travis-ci.org/WindomZ/url-generator.svg?branch=master)](https://travis-ci.org/WindomZ/url-generator)
[![Coverage Status](https://coveralls.io/repos/github/WindomZ/url-generator/badge.svg?branch=master)](https://coveralls.io/github/WindomZ/url-generator?branch=master)
[![Dependency](https://david-dm.org/WindomZ/url-generator.svg)](https://david-dm.org/WindomZ/url-generator)
[![styled with prettier](https://img.shields.io/badge/styled_with-prettier-ff69b4.svg)](https://github.com/prettier/prettier)
[![License](https://img.shields.io/badge/license-MIT-green.svg)](https://opensource.org/licenses/MIT)> Generates URL address based on the directory.
[![NPM](https://nodei.co/npm/url-gen.png)](https://nodei.co/npm/url-gen/)
[![url-gen](https://img.shields.io/npm/v/url-gen.svg)](https://www.npmjs.com/package/url-gen)
[![status](https://img.shields.io/badge/status-stable-green.svg)](https://www.npmjs.com/package/url-gen)## Features
- [x] _cli_ - Command line interface.
- [x] _custom_ - Customize `.url-gen.yml` file.## Install
```bash
npm install -g url-gen
```## Usage
```bash
$ url-gen -hUSAGE
url-gen [dir]
url-gen initARGUMENTS
[dir] Relative directory path to generate the URL optional default: "."
OPTIONS
-u, --up Query parent directory optional default: 0
GLOBAL OPTIONS
-h, --help Display help
-V, --version Display version
--no-color Disable colors
--quiet Quiet mode - only displays warn and error messages
-v, --verbose Verbose mode - will also output debug messages
```## Configuration
You need to customize the `.url-gen.yml` file, the rules configured like this:
```yaml
version: 1.0 # version number, optional
root: http://127.0.0.1:888 # defines the url root path, optional, default: http://127.0.0.1
path: example # defines the url path of the current directory, optional
```You can run ``url-gen init`` to help create.
## Example
```bash
url-gen # working in the local directory.
url-gen examples # working in the `./examples/` directory.
url-gen ~/examples # working in the `~/examples/` directory.url-gen i # creates the `.url-gen.yml` file.
url-gen init # creates the `.url-gen.yml` file.
```## Environment
- linux CI pass
- macOS CI pass
- windows Not yet tested## Contributing
Welcome to pull requests, report bugs, suggest ideas and discuss **url-generator**,
i would love to hear what you think about **url-generator** on [issues page](https://github.com/WindomZ/url-generator/issues).If you like it then you can put a :star: on it.
## License
[MIT](https://github.com/WindomZ/url-generator/blob/master/LICENSE)