note: Abandoned/incomplete. The initial idea was to split netsuite helpers into many modules.
File cabinet helpers for netsuite (suitescript 1.0).
(currently) Use browserify and require('netsuite-file')
pathInfo(pathIn : string , baseIn = '/', createFolders = false) : IPathInfo
Brings in path info relative to a base path. Creates folders if asked to and necessary.
Base path, if used, must start with '/'
Returns:
export interface IPathInfo {
folderid: number;
filename: string;
fileext: string;
nsfileext: string;
pathabsolute: string;
pathrelative: string;
baserelative: string;
}
saveFile(path : string, contents : string) : number
Shorthand for saving a file. The path must begin with '/'.