Skip to content

Commit

Permalink
Clean up options and add throw
Browse files Browse the repository at this point in the history
  • Loading branch information
iwatakeshi committed Nov 22, 2019
1 parent acb4c7f commit 049f687
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions src/interfaces/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,37 @@ import { FileStat } from 'tar'
import URLInfo from './url'

export default interface GitlyOptions {
/**
* Use cache only (default: undefined)
*/
cache?: boolean
/**
* Use both cache and local (default: undefined)
*/
force?: boolean
/**
* Throw an error when fetching (default: undefined)
*/
throw?: boolean
/**
* Set cache directory (default: '~/.gitly')
*/
temp?: string
/**
* Set the host name (default: undefined)
*/
host?: string
url?: {
/**
* Extend the url filtering method
* @param info The URLInfo object
*/
filter?(info: URLInfo): string
}
extract?: {
/**
* Extend the extract filtering method for the 'tar' library
*/
filter?(path: string, stat: FileStat): boolean
}
}

0 comments on commit 049f687

Please sign in to comment.