pathlet

1.0.0 • Public • Published

pathlet

Using this package you can find files and get their paths.

Installation:

  • Install package globally npm i -g pathlet or npm i pathlet

code example:\

  • require package as get_file_location and use

    const get_file_location = require('pathlet');
    
    get_file_location(filename, (error, result) => {
    if (error) {
        console.error(error);
    } else {
        console.log("File Location:", result);
    }
    });

Input and output:

  • Input

    get_file_location('computer.js', (error, result) => {
    if (error) {
        console.error(error);
    } else {
        console.log("File Location:", result);
    }
    });
  • Output

    File Location: /home/suraj/Desktop/packages/finder-cli/computer.js
    File Location: /home/suraj/Desktop/packages/finder-cli/com/computer.js 
    
    
    

Usage:

  • if you are in Desktop directory and search a specific file it will find all files of that exact name with extension in Desktop and all of its subdirectorires.

Package Sidebar

Install

npm i pathlet

Weekly Downloads

0

Version

1.0.0

License

ISC

Unpacked Size

3.69 kB

Total Files

4

Last publish

Collaborators

  • suraj_chandra