Linux distributions are generally full of packages that have specific uses that most people don’t need or maybe they just don’t know that they need. In my previous post I wrote about QPhotoRec which I had never used before my little accident that actually saved me a huge headache. I didn’t know that this application existed until I started researching how to undelete applications in Linux and I was pleasantly surprised that it was already included in OpenSUSE. The application below is one of many that I’ve found that make life easier for me and maybe it will for you too.

In the words of the developers, LyX is a WYSIWYM (what you see is what you mean) document processor. This is opposed to WYSIWYG (what you see is what you get) word processors like LibreOffice Writer or Microsoft Word. What does that mean? It means that what you see on the screen is only an approximation of what will go into the document. Instead of giving you a 1 to 1 representation, LyX handles the typesetting elegantly to create beautiful professional documents that would require a lot of extra work to get right in a conventional word processor. Thre is an example of this blog post written in LyX with output as a PDF at the end of this article. I didn’t choose any special fonts or any special settings to impress you. I just chose the defaults and you can see the difference in quality.

LyX is based on LaTeX which was originally developed as a cross-platform language for publishing academic papers. With LyX it’s relatively easy to include a formula like:

However, anyone who has worked with writing papers on Microsoft Word or LibreOffice can attest to it being somewhat less friendly. It can be used to write papers of course, but also full books, screenplays, and scripts, in many different formats.

You can try out LyX by installing it with zypper using:

sudo zypper in lyx

Creating a simple beautiful document is actually quite easy. Input your text first, highlight the sections that need special attention such as title, author, section, chapter headings, etc., apply the format from the menu bar, and save and then preview your document by going to Document –> View [PDF (pdflatex)]. LyX will then save your file as a temporary PDF and open it in your local PDF Reader. When you do this, prepare to see a document that looks like it was professional typeset for a textbook.

Any application this powerful is undoubtedly complex. I won’t make you think that everything is very easy and there is no learning curve. There is, but it’s really not as steep as first appears. To get you started, here are a few resources to get started with LyX.

LyX Homepage:
LyX Tutorials:

I hope to present you with more random yet useful applications in the future buried in the OpenSUSE repository.

This article via LyX.

I Deleted Everything

I goofed.

I’m an avid hobbyist photographer and I happen to live in one of the most beautiful cities in the world. Needless to say, I take a lot of pictures. Recently I upgraded the drive in my home desktop from a slow HDD to 256G SSD. My workflow is like this: I take pictures, I copy the RAW files from my SD Card to my 1.5TB external drive and then copy the ones that aren’t blurry or terrible to my local hard drive for editing and the best ones that are edited get promoted to Flickr. The SSD would make this a lot easier and faster because RAW image files tend to be relatively huge and time consuming to process.

I added the new SSD, installed Tumbleweed, copied my personal files from the old disk to the new one and then deleted the files on the old disk. I had plans to use it for another project. Except one thing; I was in the wrong directory when I deleted everything. All 400GB of pictures were gone. I immediately stopped everything because I knew that deleting files doesn’t actually remove them from the disk. It simply makes them able to be rewritten and I didn’t want to risk that happening.

How I recovered.

OpenSUSE Leap and Tumbleweed have an application called QPhotoRec that saved me.

I loaded the application with the gnomesu command as it needs root access to run:

gnomesu -c qphotorec

From here I was able to choose my disk, the kind of filesystem that I was using and where I wanted the files to be restored to and then I let it run. It’s not a fast process. It took around 8 hours to restore my 400GB and even then there was two thing that I wasn’t able to restore; the filenames and their directories. All of my files had their correct extensions but they were missing the filenames that they originally had and the directories they were in. Also, files inside of other files such as .iso or .tar files were also recovered including thumbnail photos that were stored in other files. QPhotoRec tries to make educated guesses about what is and is not a file and recovered everything but it’s not perfect. My job then was to reorganize my files into some semblance of how they were previously but at least they were there again.

Mistakes happen and hardware breaks. Files get deleted, sometimes important files. The best way to proceed is to always to keep backups (all of my most important files are encrypted and on a remote server) but when disaster happens through human error or otherwise, it’s good to know that there are options.