How to install VLC in Linux

To install VLC in linux use command:

For Fedora :(Be root user)

yum install vlc


The VLC can be found at Applications -> Sound& Video -> VLC

For ubuntu : (Be root user)

sudo apt-get update

sudo apt-get install vlc

Playing in Windows with python

Hi Friends today I have used the python os module to play around the windows os.
Here I list some of the python commands I have used in my Windows OS.
To Print the OS name been used :

>>> import os
>>> print os.name
nt

To get the language used in the OS :

>>> import locale
>>> locale.getdefaultlocale()
('en_US', 'cp1252')

To open a folder in any directory we can use startfile command which works only for windows:

>>> import os
>>> os.startfile('F:/')

To delete a file using python on Windows:

>>> import glob
>>> import os
>>> for text in glob.glob("E:\\*.txt"):
os.remove(text)

---> here text is a text file in the E:\\ directory.

How to Create a Simple Logo in GIMP

How to Create a Simple Logo in GIMP
Hi Friends , Today I have created a simple logo using GIMP . Which as easy as to type things.
To Create a logo : --

1. Start the GIMP application.
2. Then goto the file option - then goto the create option in it --
3. Now scroll down to the logos keyword where you can find a number of options there .
You can select the appropriate logo there . I have selected the Alein Glow .
4. Now a pop up window appears over there . With font options and size of text . You select the appropriate size you want . I have selected the default font option . And added a text like My Blog Is Unique To Me .

The Image I have created was :

RGB vs CMYK

RGB (Language of Light) : With RGB we can create 256 different shades of color. Combining it we can get a maximum of about 16.7 million different colors.This is created with spectrums variations. It is also called as language of light. For eg, RGB is used to create TV Monitors.The mixture of red, green and blue gives white color that is RGB.

CMYK (language of pigments): The CMY or CMYK is used in print media , Basically it is used in papers or surfaces . It is a language of pigments. The mixture of Cyan , magneta and yellow we get black color.



Inkscape Vs Gimp

Hi Friends today I have learned some differences between  the Gimp and Inkscape

Gimp :  The Gimp is a software like photoshop software  which is used for  raster images . These are mainly    used  to create the web banners and to manipulate over digital photos. Most importantly it is a open source software.


Inkscape : The Inkscape is mostly used to create the logos and it can be used as an illustrater.  It is used to process the vector images . And it is also an open source software.

Vector Images and Raster Images


Raster Images -  The raster images are  based on the pixels and we cannot find a accurate margin for it . And here we could add multiple colors based on pixels.

Vector Images - The vector images are based on mathematical conventions . In this the margins are accurate . And because of this we can change the size to any extention and the image will appear as before. But only thing we could not edit the image as it is based on mathematical convention and we will not be able to change the color of it mostly.

How To Mount Files in Linux

Hi Everyone Today I have downloaded a .iso file in my linux OS . But I dont know how to open a image file in linux , I previously used daemon software for the windows OS . And I have got some new commands for linux to mount the .iso file same as daemon software.

1.  Make a directory to mount the files :

    mkdir -p /mnt/disk

2. Now mount the image file with the command:

    mount -o loop  .iso file name /mnt/disk

3. Now locate the directory to check whether it have been loaded

   cd /mnt/disk

   ls -l                         -----> here we could find the .iso images have been created.




How to delete a file permanently in linux

Use the command in your terminal as a root user to delete the file permanently.

rm -rf (filename) -> here rm stands for remove and rf  stands for recursively and forcefully

A simple CMS using Django

Hi Friends today i have tried to create a simple cms using django :

Use the terminal

I have created a project with a name cms with command : django-admin.py cms

Then I have changed the permission of the settings file with command : chmod a+w settings.py

Then edit the settings file using a text editor and change : -

engine : sqlite3
name : (the destination) eg home/usr/cms/cms.db
(the cms.db is the name given by us so sqlite would automatically create a file with that name)

And also change the Time Zone : default given is America/Chicago (Check this link for any other information : www.djangoproject.com/documentation/settings/
)

Now create the database file using the command :  python manage.py syncdb

Now the database file will be created.


Now again edit the settings.py file and add two : python modules

django.contrib.flatpages and django.contrib.admin

Once we have added those again save and execute the command :  python manage.py syncdb

Now that command would create corresponding tables .

Then edit the urls.py file Where you have a statement (# Uncomment the next two lines to enable the admin:) uncomment it and also this  (url(r'^admin/', include(admin.site.urls)))

Now save it and then run the server using:  python manage.py runserver

Which will create a login page . Enter the username and password given while syncdb .

Now you will get a webpage like this :

And here then you could edit the sites link . And change the display name as localhost and the display domain as 127.0.0.1:8000 now save

And then click the flatpages link and change urls as /firstpage/ and give title and content whatever  you like.

Now create a folder named flatpage in cms directory. And inside it create a file called default.html

And then open the settings folder and change the directory as home/usr/cms/ and save it .

And then start the server and run the url 127.0.0.1:8000/first-page.

Now the content you have entered in the flat page appears at your browser by which we have created a simple cms in django

How to Find A Program installed directory in Linux

Hi Friends today I have tried to copy the sqlite file for django project , but as I am not familiar with linux I have to search the previously installed sqlite file , And  I have found a useful command which helps to show all the directories that are associated with that installed program.

The command I found is : rpm -ql sqlite

which showed a output like this

 /usr/bin/sqlite3
/usr/lib/libsqlite3.so.0
/usr/lib/libsqlite3.so.0.8.6
/usr/share/doc/sqlite-3.6.23.1
/usr/share/doc/sqlite-3.6.23.1/README
/usr/share/man/man1/sqlite3.1.gz