This file is indexed.

/usr/share/doc/kde/HTML/en/kubuntu/cli/files-directories.html is in kubuntu-docs 12.04.0ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
<html><head><title>File and Directory Commands</title><link rel="stylesheet" type="text/css" href="help:/common/kde-default.css"><link rel="stylesheet" type="text/css" href="help:/common/kde-docs.css"><link rel="stylesheet" type="text/css" href="help:/common/kde-localised.css"><link rel="stylesheet" type="text/css" href="help:/common/kubuntu.css"><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="Introduction To The Command Line"><link rel="up" href="index.html" title="Introduction To The Command Line"><link rel="prev" href="terminal.html" title="Starting A Terminal"><link rel="next" href="sysinfo.html" title="System Information Commands"><link rel="copyright" href="legal.html" title="Credits and License"><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><meta name="GENERATOR" content="KDE XSL Stylesheet V1.14 using libxslt"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div id="content"><div id="header"><div id="header_content"><div id="header_left"><div id="header_right"><img src="help:/common/top-kde.jpg" width="36" height="34"> File and Directory Commands</div></div></div></div><div class="navCenter"><table class="navigation"><tr><td class="prevCell"><a accesskey="p" href="terminal.html">Prev</a></td><td class="upCell"> </td><td class="nextCell"><a accesskey="n" href="sysinfo.html">Next</a></td></tr></table></div><div id="contentBody"><div class="sect1"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="files-directories"></a>File and Directory Commands</h2></div></div></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="pwd"></a>pwd - print working directory</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>pwd</strong></span></span> command displays the directory where the user is 
currently located. (<acronym class="acronym">pwd</acronym> stands for <span class="quote">&#8220;<span class="quote">print working
directory</span>&#8221;</span>). For example, typing </p><pre class="screen">pwd</pre><p> while in the 
<code class="filename">Desktop</code> directory will show 
<code class="computeroutput">/home/[username]/Desktop</code>.
</p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
<span class="application">Konsole</span> also displays this information in both the
tab and title bar of its window.
</p></div><p>
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="cd"></a>cd - change directory</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cd</strong></span></span> command changes directories. (<acronym class="acronym">cd</acronym>
stands for <span class="quote">&#8220;<span class="quote">change directory</span>&#8221;</span>). When a terminal window is opened, 
it will be in the user's home directory. Moving around the file system requires 
the use of the <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cd</strong></span></span> command.
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
To navigate into the root directory, type:
</p><pre class="screen">cd /</pre><p>
</p></li><li class="listitem"><p>
To navigate to the current user's home directory, type:
</p><pre class="screen">cd</pre><p>
or
</p><pre class="screen">cd ~</pre><p>
</p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>~</strong></span></span> character represents the current user's home 
directory. As shown above, <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cd ~</strong></span></span> is equivalent to <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cd
/home/username/</strong></span></span>. However, when running a command as root (using
<span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>sudo</strong></span></span>, for example), <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>~</strong></span></span> points to <code class="filename">/root</code>. When running a <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cd</strong></span></span> command
with <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>sudo</strong></span></span>, the full path to the home directory must be given.
</p></div></li><li class="listitem"><p>
To navigate up one directory level, type:
</p><pre class="screen">cd ..</pre><p>
</p></li><li class="listitem"><p>
To navigate up two directory levels, type:
</p><pre class="screen">cd ../../</pre><p>
</p></li><li class="listitem"><p>
To navigate to the previous directory (go back), type:
</p><pre class="screen">cd -</pre><p>
</p></li><li class="listitem"><p>
To navigate through multiple levels of directories at once, specify the full
directory path. For example, type:
</p><pre class="screen">cd /var/log</pre><p>
to go directly to the <code class="filename">/log</code> subdirectory
of <code class="filename">/var/</code>. For another example, typing:
</p><pre class="screen">cd ~/Desktop</pre><p> 
moves to the <code class="filename">Desktop</code> subdirectory inside the current user's 
home directory.
</p></li></ul></div></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="ls"></a>ls - list files</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>ls</strong></span></span> command outputs a list of the files in the current
directory. (<acronym class="acronym">ls</acronym> is short for <span class="quote">&#8220;<span class="quote">list</span>&#8221;</span>). For 
example, typing  </p><pre class="screen">ls ~</pre><p> will display the files that are in the 
current user's home directory.
</p><p>
Used with the <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>-l</strong></span></span> option, <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>ls</strong></span></span> outputs other
information along with the filename, such as the permissions on the file, the
file's owner, and more.
</p><p>
Used with the <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>-al</strong></span></span> options, <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>ls</strong></span></span> outputs
the information associated with the <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>-l</strong></span></span> option in addition to
showing hidden files (<span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>a</strong></span></span> option).
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="touch"></a>touch - create empty file</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>touch</strong></span></span> command is used to change a file's access and 
modification timestamps or to create a new empty file. For example, 
</p><pre class="screen">touch foo</pre><p> will create a new empty file named 
<code class="filename">foo</code>. If <code class="filename">foo</code> is already a file, then 
using <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>touch</strong></span></span> will update the timestamps on the file, which 
show the last time a file was <span class="emphasis"><em>touched</em></span>.
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="mkdir"></a>mkdir - make directory</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>mkdir</strong></span></span> command is used to create a new directory. 
(<acronym class="acronym">mkdir</acronym> stands for <span class="quote">&#8220;<span class="quote">make directory</span>&#8221;</span>). To create 
a new directory named <code class="filename">foobar</code>, type:
</p><pre class="screen">mkdir foobar</pre><p>
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="cp"></a>cp - copy files or directories</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>cp</strong></span></span> command makes a copy of a file or directory. 
(<acronym class="acronym">cp</acronym> is short for <span class="quote">&#8220;<span class="quote">copy</span>&#8221;</span>). To make an exact copy
of <code class="filename">foo</code> and name it <code class="filename">bar</code>, type:
</p><pre class="screen">cp foo bar</pre><p>
To make an exact copy of the <code class="filename">foo_dir</code>
directory and name it <code class="filename">bar_dir</code>, type:
</p><pre class="screen">cp -r foo_dir bar_dir</pre><p>
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="mv"></a>mv - move files or directories</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>mv</strong></span></span> command moves a file or directory to a different
location or renames a file or directory. (<acronym class="acronym">mv</acronym> is short for
<span class="quote">&#8220;<span class="quote">move</span>&#8221;</span>). To rename the file <code class="filename">foo</code> to
<code class="filename">bar</code>, type: </p><pre class="screen">mv foo bar</pre><p> To move the file 
<code class="filename">foo</code> into the current user's <code class="filename">Desktop</code> directory, type: </p><pre class="screen">mv foo 
~/Desktop</pre><p> This will not rename <code class="filename">foo</code> to 
<code class="filename">Desktop</code>, because <code class="filename">foo</code> is a file and 
<code class="filename">Desktop</code> is a directory.
</p></div><div class="sect2"><div class="titlepage"><div><div><h3 class="title"><a name="rm"></a>rm - remove files or directories</h3></div></div></div><p>
The <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>rm</strong></span></span> command is used to delete files and directories. 
(<acronym class="acronym">rm</acronym> is short for <span class="quote">&#8220;<span class="quote">remove</span>&#8221;</span>). To delete the file
<code class="filename">foo</code> from the current directory, type: 
</p><pre class="screen">rm foo</pre><p>
</p><p>
By default, <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>rm</strong></span></span> will not remove directories. To remove a
directory, you must use the <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>-r</strong></span></span> option (which can also be 
entered as <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>-R</strong></span></span> or <span xmlns:doc="http://nwalsh.com/xsl/documentation/1.0" class="command"><span class="command"><strong>--recursive</strong></span></span>). For 
example, </p><pre class="screen">rm -r foobar</pre><p> or </p><pre class="screen">rm -R foobar</pre><p> or 
</p><pre class="screen">rm --recursive foobar</pre><p> will remove the directory 
<code class="filename">foobar</code> <span class="emphasis"><em> and all of its 
contents!</em></span>
</p></div></div></div><div id="footer"><div class="navCenter"><table class="navigation"><tr><td class="prevCell"><a accesskey="p" href="terminal.html">Prev</a></td><td class="upCell"><a accesskey="h" href="index.html">Home</a></td><td class="nextCell"><a accesskey="n" href="sysinfo.html">Next</a></td></tr><tr><td class="prevCell">Starting A Terminal </td><td class="upCell"> </td><td class="nextCell"> System Information Commands</td></tr></table></div><div id="footer_text"><br><a href="mailto:ubuntu-docs@lists.ubuntu.com" class="footer_email">
	  Ubuntu Documentation Project
        </a></div></div></div></body></html>