Install Ghostscript and use the following syntax -
gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=final.pdf file1.pdf file2.pdf
Using Ghostscript to concatenate two pdf files
0
Posted by Sandeep Pathak | Labels: Ghostscript, Linux | Posted on Monday, December 6, 2010
Extracting fields from multiple files using awk
1
Posted by Sandeep Pathak | Labels: awk, Linux | Posted on Sunday, February 7, 2010
paste file1 file2 | awk '{print $2 " " $4}'
We can do more! Suppose you want to add column 1 of file1 to column 3 of file2. This can be accomplished using the following command:
paste file1 file2 | awk '{print $1-$6}'
Installing Mathabx package for latex in Ubuntu
1
Posted by Sandeep Pathak | Labels: Latex, Linux, Mathabx, Ubuntu | Posted on Sunday, September 27, 2009
- Download mathabx.zip from the following link.
- $ unzip mathabx.zip
- $ cd mathabx
- $ sudo mkdir $TEXMF/fonts/source/public/mathabx
In Ubuntu 9.04, TEXMF is /usr/share/texmf-texlive - sudo cp source/*.mf $TEXMF/fonts/source/public/mathabx
- sudo cp texinputs/* $TEXMF/tex/generic/misc/
- Update the database
$ sudo texconfig rehash - Update the format file
$ sudo fmtutil --refresh - When you build your tex document, you might get an error that /Asterisk is defined again - To avoid that, comment the line in mathabx.dcl where /Asterisk is defined.
$ sudo gedit $TEXMF/tex/generic/misc/mathabx.dcl
Search for line where /Asterisk is present in mathabx.dcl and put a % sign at the start of the line. - You are all set!
Scheduled Shutdown using cron
0
Posted by Sandeep Pathak | Labels: Ubuntu, Utilities | Posted on Thursday, May 14, 2009
$ crontab -eIn the editor window write
0 9 * * * /sbin/shutdown -h nowThis will shutdown your computer at 9 hrs. After this restart cron service:
sudo /etc/init.d/cron restart
Change file permissions recursively without affecting directories
0
Posted by Sandeep Pathak | Labels: Linux | Posted on Tuesday, May 12, 2009
find . ! -type d -exec chmod 600 {} \;
Starting enumerate with a specified number in Latex
0
Posted by Sandeep Pathak | Labels: Latex | Posted on Tuesday, November 25, 2008
\begin{enumerate}
\setcounter{enumi}{5}
\item Hello
\item Bye
\end{enumerate}
TRICK TO GET FONTS CORRECT IN FEDORA 9
0
Posted by Sandeep Pathak | Labels: Fedora, Font Problems, Mathematica | Posted on Tuesday, November 18, 2008
On a 32-bit machine
rm -f /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtCore.so.4
rm -f /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtGui.so.4
ln -s /usr/lib/libQtCore.so.4 /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtCore.so.4
ln -s /usr/lib/libQtGui.so.4 /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtGui.so.4
On a 64-bit machine,
rm -f /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtCore.so.4
rm -f /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtGui.so.4
ln -s /usr/lib64/libQtCore.so.4 /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtCore.so.4
ln -s /usr/lib64/libQtGui.so.4 /usr/local/Wolfram/Mathematica/6.0/SystemFiles/Libraries/Linux/libQtGui.so.4





