Menu

linux/

How to format USB stick as FAT32

First step is to find the name of the USB stick in the system:

sudo fdisk -l

In my case the name of the device is /dev/sdc If the USB stick is mounted, unmount it with command:

sudo umount /dev/sdc

Finally, run the command to format USB stick:

mkdosfs -F 32 -I /dev/sdc
· 1 Jan 2016

How to remove all *.pyc files

Remove all *.pyc files from the current directory (and subdirectories):

find . -name \*.pyc -delete
· 1 Jan 2015

Disable Komodo Edit file association

Remove

text/plain=komodo-edit-9.desktop

from file

~/.local/share/applications/defaults.list
· 1 Jan 2015

Automatically start application during the boot

To start an application automatically in fedora, you need to create a *.desktop file in the directory ~/.config/autostart, for example:

gedit ~/.config/autostart/flux.desktop

The content of the file can be something like:

[Desktop Entry]
Type=Application
Name=flux
Comment=xflux
Exec=/home/jsn/app/xflux -l 52.3837151 -g 4.8806328
Terminal=false
· 1 Jan 2015

How to find out which package provides a specific file

If you need to find out, for example, which package in fedora provides htpasswd command, you may do it with the command:

yum provides \*bin/htpasswd
· 1 Jan 2015