Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

readme.md 1.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. # path-type [![Build Status](https://travis-ci.org/sindresorhus/path-type.svg?branch=master)](https://travis-ci.org/sindresorhus/path-type)
  2. > Check if a path is a file, directory, or symlink
  3. ## Install
  4. ```
  5. $ npm install path-type
  6. ```
  7. ## Usage
  8. ```js
  9. const {isFile} = require('path-type');
  10. (async () => {
  11. console.log(await isFile('package.json'));
  12. //=> true
  13. })();
  14. ```
  15. ## API
  16. ### isFile(path)
  17. Check whether the passed `path` is a file.
  18. Returns a `Promise<boolean>`.
  19. #### path
  20. Type: `string`
  21. The path to check.
  22. ### isDirectory(path)
  23. Check whether the passed `path` is a directory.
  24. Returns a `Promise<boolean>`.
  25. ### isSymlink(path)
  26. Check whether the passed `path` is a symlink.
  27. Returns a `Promise<boolean>`.
  28. ### isFileSync(path)
  29. Synchronously check whether the passed `path` is a file.
  30. Returns a `boolean`.
  31. ### isDirectorySync(path)
  32. Synchronously check whether the passed `path` is a directory.
  33. Returns a `boolean`.
  34. ### isSymlinkSync(path)
  35. Synchronously check whether the passed `path` is a symlink.
  36. Returns a `boolean`.
  37. ## License
  38. MIT © [Sindre Sorhus](https://sindresorhus.com)