Please enable JavaScript to view this site.

A-Shell Reference

Navigation: Subroutines > MIAMEX

MX_SYNC_CWD

Scroll Prev Top Next More

Reviwed and revised May 2024

xcall MIAMEX, MX_SYNC_CWD {, status}

MX_SYNC_CWD (MIAMEX 17) synchronizes the host OS's current working directory location with A-Shell's current working directory location.

Parameters

status  (Integer)  [out]

returns 0 for success, else error

Although A-Shell DevPPN directories generally correspond one-to-one with native directories on the host operating system, it is not automatically the case that the operating system’s idea of your current working directory will always match up to your A-Shell login directory. MX_SYNC_CWD (MIAMEX 17) may be used at any point to resolve this problem by synchronizing the current working directory with that of the current PPN. This is generally only of interest when interfacing to some host operating facility or executing a native operating system command.

A call to this function is automatically made by LOG.LIT and by HOST.LIT in order to minimize problems. If a different utility is written to change PPN or execute a host command, it might be advantageous to synchronize the working directory.

See MX_GETENV for a way to query the current host operating system working directory.