Added frames around commands
This commit is contained in:
parent
1e54c12a9c
commit
1b7e6ca232
@ -1,3 +1,3 @@
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
find "$PWD"
|
||||
\end{Verbatim}
|
||||
@ -4,25 +4,25 @@
|
||||
|
||||
\lettrine[]{U}{se} the \texttt{pdftoppm}\index{pdftoppm} command (from the \label{poppler-utils} \texttt{poppler-utils}\index{poppler-utils} package) to convert part or all of a pdf to an image. For example, to convert a pdf to a png:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
pdftoppm input.pdf output -png
|
||||
\end{Verbatim}
|
||||
|
||||
This will convert each page in the pdf to a png using the format ``output-01.png'' where ``01'' is the page number. To convert a single page of a multipage pdf, use the \texttt{-f} flag to specify which page to use. For example, this will convert page 5 to a png:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
pdftoppm input.pdf output -png -f 5 -singlefile
|
||||
\end{Verbatim}
|
||||
|
||||
To convert a range of pages, use the \texttt{-f} flag to specify the first page to convert and use the \texttt{-l} flag to specify the last page of the range:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
pdftoppm input.pdf output -png -f 5 -l 10 -singlefile
|
||||
\end{Verbatim}
|
||||
|
||||
The default resolution is 150 dpi. To change this, use the \texttt{-rx} flag to specify the resolution along the x-axis, and the \texttt{-ry} flag to specify the resolution along the y-axis;
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
pdftoppm input.pdf output -png -rx 300 -ry 300
|
||||
\end{Verbatim}
|
||||
|
||||
|
||||
@ -12,31 +12,32 @@ foo38r.txt
|
||||
|
||||
To remove the ``foo'', use this command:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
mmv 'foo*' '#1'
|
||||
\end{Verbatim}
|
||||
|
||||
To change ``foo'' to ``bar'', use:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
mmv 'foo*' 'bar#1'
|
||||
\end{Verbatim}
|
||||
|
||||
The \texttt{mmv} command uses this command structure:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\vspace{3mm}
|
||||
\begin{Verbatim}[frame=single, breaklines=true, framesep=3mm, label=\fbox{mmv Command Structure}]
|
||||
mmv [-m|x|r|c|o|a|l|s] [-h] [-d|p] [-g|t] [-v|n] [--] [from to]
|
||||
\end{Verbatim}
|
||||
|
||||
For a full discussion of those, see the ``man'' page. The key concept here is that wildcard characters in the ``from'' option get replaced with ``\#1'', ``\#2'' etc in the ``to'' option, in the order they are encountered. So it is possible to reorder elements of file names. For example, to exchange ``foo'' in our list above for the file extension, we would use:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
mmv 'foo*.txt' 'txt#1.foo'
|
||||
\end{Verbatim}
|
||||
|
||||
To reverse the order of the last three characters of the filenames, we would use:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
mmv 'foo???.txt' 'foo#3#2#1.txt'
|
||||
\end{Verbatim}
|
||||
|
||||
@ -58,13 +59,13 @@ foor83.txt
|
||||
|
||||
To obtain this list with a relative path, use:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
find .
|
||||
\end{Verbatim}
|
||||
|
||||
To find only certain types of files (in this case jpgs) and redirect this information to a file, use something like this:
|
||||
|
||||
\begin{Verbatim}[]
|
||||
\begin{Verbatim}[frame=single, breaklines=true]
|
||||
find . \( name "*.jpg" -o name "*.jpeg" \) > jpglist.txt
|
||||
\end{Verbatim}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user