Saturday, 23 October 2010

What is Organic User Interfaces (OUI)?


Organic User Interfaces: In the future of computing flourishing with thousands of shapes of computing devices that will be as scalable, flexible, and transformable as organic life itself.Organic User Interfaces we can see following characteristics.


1.) Input Equals Output -->In other words output display will become Input.currently we use joystick,keyboard or mouse in order interact with display devices.But in near future those input devices are not sufficient.Therefore OUI use same output as its input device.




2.) Function Equals Forms-->Where the display can take any shape alternatively,Physical shape will results what can do with it.Physical shape goes with its function in other words form of the display equals its function.




3.) Forms Follow Flow-->Where the display can change their shape.Shape can be dynamically change according to situation and activity.e.g. the ubiquitous 'clamshell' phone, where incoming calls alter the phone's function when opening the phone during an incoming call.





sources Wikipedia and organicui

Tuesday, 12 October 2010

How to install Gitosis


Firstly, grab the source from the git web repository.
$ cd /usr/local/src
$ git clone git://eagain.net/gitosis.git
Initialized empty Git repository in /usr/local/src/gitosis/.git/
remote: Counting objects: 603, done.
remote: Compressing objects: 100% (172/172), done.
remote: Total 603 (delta 425), reused 597 (delta 422) Receiving objects: 100% (603/603), 92.87 KiB | 23 KiB/s, done. Resolving deltas: 100% (425/425), done.
Once downloaded, we can run the installation.
$ cd gitosis
$ python setup.py install
Then we need to create user
sudo adduser \
    --system \
    --shell /bin/sh \
    --gecos 'git version control' \
    --group \
    --disabled-password \
    --home /home/git \
    git
$ sudo -s
root $ su -git
$ ssh-keygen -t rsa
Generating public/private rsa key pair. Enter file in which to save the key (/home/git/.ssh/id_rsa): Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in /home/git/.ssh/id_rsa. Your public key has been saved in /home/git/.ssh/id_rsa.pub. The key fingerprint is: 59:a8:a8:0a:f7:b5:0e:eb:74:c4:66:cb:ac:03:84:da git@localhost The key's randomart image is:
+--[ RSA 2048]----+
|                 |
|         .       |
| .      . .      |
|. .  o . o       |
|.o  . * S        |
|. E. * .         |
|. o.o *          |
|.o o.* .         |
|.  .=oo          |
+-----------------+
git$ ls -al .ssh
total 16
drwx------ 2 git git 4096 2009-02-11 14:52 .
drwx------ 5 git git 4096 2009-02-11 14:52 ..
-rw------- 1 git git 1743 2009-02-11 14:52 id_rsa
-rw-r--r-- 1 git git  393 2009-02-11 14:52 id_rsa.pub
Now we initialize keys to git repository
git$ gitosis-init < .ssh/id_rsa.pub
Initialized empty Git repository in /home/git/repositories/gitosis-admin.git/ Reinitialized existing Git repository in /home/git/repositories/gitosis-admin.git/
Just look at the file permissions it is important the git user has privileges to access data.
git$ ls -al
Same way look at the repositories.
git$ ls -al repositories/
total 12
drwxr-xr-x 3 git git 4096 2009-02-11 14:57 .
drwx------ 7 git git 4096 2009-02-11 14:57 ..
drwxr-x--- 8 git git 4096 2009-02-11 14:57 gitosis-admin.git
Now we are going to clone gitosis-admin.git.
git$ git clone git@localhost:gitosis-admin.git
Initialized empty Git repository in /home/git/gitosis-admin/.git/ Enter passphrase for key '/home/git/.ssh/id_rsa':
remote: Counting objects: 5, done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 5 (delta 0), reused 5 (delta 0) Receiving objects: 100% (5/5), done.
Creating New Repositories
Lets allow group persmissions.
git$ ls -al repositories/gitosis-admin.git/hooks/post-update-rw-r--r-- 1 git git 69 2009-02-11 14:57 repositories/gitosis-admin.git/hooks/post-updategit$ chmod 755 repositories/gitosis-admin.git/hooks/post-update
git$ ls -al repositories/gitosis-admin.git/hooks/post-update 
-rwxr-xr-x 1 git git 69 2009-02-11 14:57 repositories/gitosis-admin.git/hooks/post-update
Now, Lets take a look at the gitosis-admin source code we checked out .
git$ ls -al gitosis-admin
total 20
drwxr-xr-x 4 git git 4096 2009-02-11 15:38 .
drwx------ 8 git git 4096 2009-02-11 15:49 ..
drwxrwxr-x 8 git git 4096 2009-02-11 15:38 .git
-rw-rw-r-- 1 git git   81 2009-02-11 15:38 gitosis.conf
drwxrwxr-x 2 git git 4096 2009-02-11 15:38 keydir
We can configure gitosis.conf.
git$ cd gitosis-admin
git$ vi gitosis.conf
  1 [gitosis]
  2
  3 [group gitosis-admin]
  4 writable = gitosis-admin
  5 members = git@localhost
  6
  7 [group my-staff]
  8 writable = my-first-repo
  9 members = git@localhost

git$ git commit -a -m "Allow my staff access to my-first-repo"
[master]: created 0c6a685: "Allow my staff access to my-first-repo"
1 files changed, 3 insertions(+), 0 deletions(-)

git$ git push
Enter passphrase for key '/home/git/.ssh/id_rsa':
Counting objects: 5, done.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 381 bytes, done.
Total 3 (delta 0), reused 0 (delta 0)
To git@localhost:gitosis-admin.git
   7b3ddbe..0c6a685  master -&gt; master

git$ cd
Then we are going to create our first repository.
git$ mkdir my-first-repo
git$ cd my-first-repo
git$ git init
Initialized empty Git repository in /home/git/my-first-repo/.git/
git$ git remote add origin git@localhost:my-first-repo.git
git$ echo "Hello" &gt; README.txt
git$ git add README.txt
git$ git commit -a -m "Initial Revision"
[master (root-commit)]: created 6f567f9: "Initial Revision"
1 files changed, 1 insertions(+), 0 deletions(-)
create mode 100644 README.txt
git$ git push origin master:refs/heads/master
Enter passphrase for key '/home/git/.ssh/id_rsa':
Counting objects: 3, done.
Writing objects: 100% (3/3), 220 bytes, done.
Total 3 (delta 0), reused 0 (delta 0)
To git@localhost:my-first-repo.git
* [new branch]      master -&gt; master
git$ cd ..
Now we have new repository,finally we can add new users.
git$ cd gitosis-admin
git$ cp ~/alice.pub keydir
git$ cp ~/bob.pub keydir
git$ git add keydir
git$ vi gitosis.conf
  1 [gitosis]
  2
  3 [group gitosis-admin]
  4 writable = gitosis-admin
  5 members = git@localhost
  6
  7 [group my-staff]
  8 writable = my-first-repo
  9 members = alice bob
git$ git commit -a -m "alice/bob writable to my-first-repo"
[master]: created 17b3295: "alice/bob writable to my-first-repo"
1 files changed, 1 insertions(+), 1 deletions(-)
create mode 100644 keydir/alice.pub
create mode 100644 keydir/bob.pub
git$ git push
Enter passphrase for key '/home/git/.ssh/id_rsa':
Counting objects: 8, done.
Compressing objects: 100% (4/4), done.
Writing objects: 100% (5/5), 430 bytes, done.
Total 5 (delta 1), reused 0 (delta 0)
To git@magneto:gitosis-admin.git
   305600f..17b3295  master -&gt; master
now users can access our central repository.
alice$ git clone git@SERVER_HOSTNAME:my-first-repo.git

Monday, 4 October 2010

Install GIT

How to install Git

sudo apt-get install git-core
add user name and email

 git config --global user.name "name"
 git config --global user.email "email id"

go to the project folder and

cd project folder
we can see our config file by typing this

cat /project folder/.config/
we can enable command colors by using

git config --global color.ui true
we go to folder  and  initialize the project repository.

git init
git commit
git commit  -m ' comment'
git add  

now we can use following commands

git diff --cached
git log  


finally update the server info

sudo -u git update-server-info
now we have access to repository .we can use commit pull push command
For instance http://localhost/efp/.git/


I found some useful resources
http://git.or.cz/course/svn.html
http://sysmonblog.co.uk/misc/git_by_example/
http://www.kernel.org/pub/software/scm/git/docs/user-manual.html

Install GIT web


Intsall the application
sudo apt-get install  gitweb

Create a new folder in /var/www and change into that directory like:

sudo mkdir /var/www/gitweb
cd /var/www/gitweb  

Create a softlink to the /var/www/gitweb folder from where the css and the pics of gitweb originally do reside:

sudo ln -s /usr/share/gitweb/* .
Now we have all things linked to the correct place.
Then we need to modify the apache.conf. This must happen only if we do not have already this line enabled in apache.conf:

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
So if this line isn’t in your apache.conf, then add this line and another one like:
sudo nano /etc/apache2/apache.conf   
##add the following two lines:
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
Include /etc/gitweb/apache.conf  
Then we need to create a folder in /etc namely “gitweb” and add the apache.conf for gitweb there.

 sudo mkdir /etc/gitweb
Then we  add a file namely apache.conf in it like:

sudo nano /etc/gitweb/apache.conf
And we add the following code in it:


Options Indexes FollowSymlinks ExecCGI
DirectoryIndex /cgi-bin/gitweb.cgi
AllowOverride All

Save the file. Then we need to configure the last file, namely gitweb.conf:
sudo nano /etc/gitweb.conf  
There we have to enter the following code:

$# path to git projects (.git)  
$projectroot = "/var/www/";  

# directory to use for temp files
$git_temp = "/tmp";  

# target of the home link on top of all pages
#$home_link = $my_uri || "/";  

# html text to include at home page
$home_text = "indextext.html";  

# file with project list; by default, simply scan the projectroot dir.
$projects_list = $projectroot;  

# stylesheet to use
$stylesheet = "/gitweb/gitweb.css";    

Finally: restart the server like:

sudo /etc/init.d/apache2 restart

Friday, 1 October 2010

Install FreeNX via putty+xming

    Installing the FreeNX server on Ubuntu 9.10.
    I use putty.exe + xming to login to ubuntu via ssh

$sudo add-apt-repository ppa:freenx-team
$sudo apt-get update
$sudo aptitude install freenx

   Now use nxsetup to install necessary files and create the special user "nx"
   $sudo /usr/lib/nx/nxsetup --install

   FreeNX Client installation in ubuntu 9.10 
   If you want to install opensource client for freenx use QTNX,QTNX NX client for QT instal
   qtnx using as follows.

   $sudo apt-get install qtnx

   Install Freenx client in windows
   You can download freenx windows client from here and install.

For start
$sudo /etc/init.d/freenx-server start
For stop
$sudo /etc/init.d/freenx-server stop

Errors..
If you get Cannot initialize the display service problems follow this instructions
 If you get "The nx service is not available or the nx access was disabled" error
To fix this, connect to your SSH and type:
$cat /var/lib/nxserver/home/.ssh/client.id_dsa.key
Copy the text you get and in your NX client, on your login dialog box go to:
Configure… > General Tab > Key