| 1 |
.TH KPSEACCESS 1 "1 March 2011" "Kpathsea 6.4.2" |
| 2 |
.\"===================================================================== |
| 3 |
.if n .ds MP MetaPost |
| 4 |
.if t .ds MP MetaPost |
| 5 |
.if n .ds MF Metafont |
| 6 |
.if t .ds MF M\s-2ETAFONT\s0 |
| 7 |
.if t .ds TX \fRT\\h'-0.1667m'\\v'0.20v'E\\v'-0.20v'\\h'-0.125m'X\fP |
| 8 |
.if n .ds TX TeX |
| 9 |
.ie t .ds OX \fIT\v'+0.25m'E\v'-0.25m'X\fP for troff |
| 10 |
.el .ds OX TeX for nroff |
| 11 |
.\" the same but obliqued |
| 12 |
.\" BX definition must follow TX so BX can use TX |
| 13 |
.if t .ds BX \fRB\s-2IB\s0\fP\*(TX |
| 14 |
.if n .ds BX BibTeX |
| 15 |
.\" LX definition must follow TX so LX can use TX |
| 16 |
.if t .ds LX \fRL\\h'-0.36m'\\v'-0.15v'\s-2A\s0\\h'-0.15m'\\v'0.15v'\fP\*(TX |
| 17 |
.if n .ds LX LaTeX |
| 18 |
.\"===================================================================== |
| 19 |
.SH NAME |
| 20 |
kpseaccess \- determine whether a file can be accessed |
| 21 |
.SH SYNOPSIS |
| 22 |
.B kpseaccess |
| 23 |
.I mode |
| 24 |
.I file |
| 25 |
.\"===================================================================== |
| 26 |
.SH DESCRIPTION |
| 27 |
Exit successfully if |
| 28 |
.I file |
| 29 |
can be accessed with the specified |
| 30 |
.IR mode . |
| 31 |
The |
| 32 |
.I mode |
| 33 |
is an optional dash |
| 34 |
.RB (` \- ') |
| 35 |
followed by zero or more letters of |
| 36 |
.BR rwx , |
| 37 |
where |
| 38 |
.B r |
| 39 |
is for readable, |
| 40 |
.B w |
| 41 |
is for writable, and |
| 42 |
.B x |
| 43 |
is for executable. |
| 44 |
.PP |
| 45 |
The difference between |
| 46 |
.B kpseaccess |
| 47 |
and |
| 48 |
.B test |
| 49 |
is that the latter looks at the permission bits, while the former |
| 50 |
checks using the |
| 51 |
.BR access (2) |
| 52 |
system call. This makes a difference when file systems have been |
| 53 |
mounted read-only. |
| 54 |
.\"===================================================================== |
| 55 |
.SH OPTIONS |
| 56 |
.B kpseaccess |
| 57 |
accepts the following options: |
| 58 |
.TP |
| 59 |
.B --help |
| 60 |
Print help message and exit. |
| 61 |
.TP |
| 62 |
.B --version |
| 63 |
Print version information and exit. |
| 64 |
.\"===================================================================== |
| 65 |
.SH "SEE ALSO" |
| 66 |
.BR access (2) |