edgeport - v1.0.3
    Preparing search index...

    Function exists

    • One-shot: connects, checks whether a path exists, and closes the session.

      Parameters

      Returns Promise<boolean>

      true if the path exists, else false.

      If the connection or handshake fails.

      If authentication is rejected.

      1.0.2

      import { exists } from 'edgeport/ssh';
      const there = await exists({ hostname: 'h', username: 'u', password: 'p', path: '/etc/hosts' });