https://github.com/webini/guessit-exec
Call the Guessit python script
https://github.com/webini/guessit-exec
Last synced: about 1 year ago
JSON representation
Call the Guessit python script
- Host: GitHub
- URL: https://github.com/webini/guessit-exec
- Owner: Webini
- Created: 2016-12-15T21:22:35.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-12-15T21:32:14.000Z (over 9 years ago)
- Last Synced: 2025-03-07T05:06:02.163Z (over 1 year ago)
- Language: JavaScript
- Size: 3.91 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Guessit-exec
============
## Description
Guessit exec is a simple method that allow you to call the python binary of guessit v2 in nodeJS
## Requirements
You must install [guessit v2](https://github.com/guessit-io/guessit) before using this script
## Usage
```js
const guessit = require('guessit-exec');
guessit('South.Park.s01.e01.720.mkv')
.then((data) => {
console.log(data);
})
.catch((e) => {
console.log(e);
});
```
## Prototype
```c
Promise guessit(String filename, Object options)
```
Guessit method return an es6 promise.
### Options Object
Field name | Value allowed | Guessit Parameter
---------- | ------------- | -----------------
type | string | --type |
config | string | --config |
nameOnly | boolean | --name-only |
dateYearFirst | boolean | --date-year-first |
dateDayFirst | boolean | --date-day-first |
allowedLanguages | array | -L |
allowedCountries | array | -C |
episodePreferNumber | boolean | -E |
expectedTitle | string | -T |
expectedGroup | string | -G |
advanced | boolean | -a
For more information about guessit parameter, go to [Guessit Documentation](http://guessit.readthedocs.io/en/latest/)