Friday, June 29, 2012

Android 4.1 Jelly Bean Features & Improvements


Android-4.1-Jelly-Bean-New-Features
The fifth Google I/O began today amidst much anticipation fueled by recent announcements, rumors and leaks regarding Google’s flagship Android tablet, and the latest version of their mobile OS, Android 4.1 Jelly Bean, which is what we’ll be discussing here. Although not as huge an iteration as Ice Cream Sandwich, Jelly Bean adds a lot of much sought-after features, interface tweaks and improvements, while keeping almost all of its overall look the same as that of the former. Join us after the break for a summary of the salient new features and improvements in Jelly Bean.

Project Butter

Through all iterations of the Android OS, one very prominent blemish has been its comparatively slower UI. Slower compared to its major competitors (iOS & Windows Phone), that is. Jelly Bean aims to fix this. Labeled Project Butter, the combination of Vsync, triple buffering and greater touch responsiveness is sure to make interactions with the interface feel much, much faster and smoother. The frame rate of the Jelly Bean UI seems to be miles ahead of its predecessor (as can be seen in the video embedded below), and going by the demo presented at Google I/O, the same can be said about its responsiveness, which is driven by a new model that increases the CPU’s processing speed every time the OS detects a touch.

Expandable & Actionable Notifications

The new notifications come packed with more information and actions, enough to help you perform all essential tasks from within the notification drawer, without having to actually launch each individual app.  You will be able to drag down on a notification with two fingers to expand it for extra info and options (such as previews for multiple text and Gmail messages, Google+ photo previews, +1 and Reshare options for Google+ notifications, Comment and Like for Foursqaure, Call back and Message for missed calls, etc).
Jelly Bean Notifications

Improved Keyboard With Next Word Prediction

Jelly Bean boasts new and improved text input with Swiftkey and Swype-like next word prediction. The accuracy of the prediction is yet unknown, of course. Though, seeing as it’s Google’s work, I’m guessing it’ll be as good as, if not better than, that of the aforementioned keyboard replacement apps.
Jelly Bean Keyboard

Offline Voice Typing

That’s right. Jelly Bean will allow users to dictate to their devices without an internet connection. This is something that Android users have been craving for since forever. third-party apps have been offering for quite a while now, but compared to Google’s speech-to-text, their functionality is extremely limited.

Smarter Home Screen With Auto-Arranging Of Icons & Widgets

The JB home screen takes a page out of the iOS book with the addition of auto-arrange. This feature will automatically arrange both icons and widgets for you as you move them around and between different home screens. For example, if you move a widget to a home screen that doesn’t have enough space for it, the widget will be resized to fit within the empty space on said screen.
Jelly-Bean-Widget-Resizing

Accessibility

Jelly Bean will come with gestures and speech feedback for blind users. It will allow installation of accessibility plugins to connect external braille input devices through Bluetooth.
Jelly-Bean-Accessibility

Enhanced Camera App With A Film Strip View & Faster Deletion

The Camera app has been improved to facilitate faster switching between the camera viewfinder and captured photos. You can swipe across the screen to view the last photo you captured and pinch to switch to a new film strip view, where you can quickly swipe a photo up off the screen to delete it. Accidental deletes can be undone.
Jelly-Bean-Improved-Camera-App

Improved Android Beam

In Jelly Beam, you will be able to tap two NFC-enabled Android devices together to share photos and videos as well. Moreover, you will be able to pair your Android device in the same manner with Bluetooth devices that support Simple Secure Pairing. That’s right; through a simple tap, without having to manually search for and pair with them.
Jelly-Bean-Android-Beam

Enhanced Google Search, Voice Search

Google Search has received a complete UI overhaul, now makes use of Google’s Knowledge Graph to provide the best results from various sources and allows more natural queries (for example, “how tall is the Eiffel Tower?”). Voice Search has a voice of its own this time around. It too allows natural queries, provides equally natural responses (much like Siri), and the voice output sounds much more human-like than any other.
It’s a little too early to be comparing Jelly Bean’s Voice Search to Siri. Though, the former does seem like it could give the popular iOS voice assistant a run for its (her?) money. If not alone, then coupled with Google Now.
Jelly-Bean-Google-Voice-Search

Google Now

Arguably the most significant addition to the OS, Google Now is a smart search assistant of sorts with a plethora of functions. It can be launched by tapping the search bar on the home screen or swiping up from the bottom edge of the screen (which means it should be accessible from anywhere within the OS).
Google Now aims to assist you with several on-the-go requirements. It detects where you are and provides you with optimal routes to required destinations. It tells you when to set off for a destination if you want to reach there at a particular time, picks the shortest route and estimates your time of arrival. That’s not all. Google Now will cater for your flight tracking needs and automatically provide you with essential info (like currency conversion rates) while your travelling. It displays suggestions for places near your current location that you might fancy, keeps you up to date with your favorite sports teams and allows you to purchase tickets to their events from within its interface.
Jelly-Bean-Google-Now
The best thing about it is that you don’t have to go through the trouble of making the queries yourself; it automatically fetches everything for you and arranges it in separate cards within its UI, which changes its header with respect to the current location and time of day.

Barring Google Now and the new notifications, the changes introduced in Android Jelly Bean might seem insignificant to a few at first glance, but they are sure to change user experience dramatically. Project Butter, in particular, could silence all those anti-Android taunts that label the OS invariably laggy.
Android 4.1 Jelly Bean will begin to roll out for Galaxy Nexus, Nexus S and Motorola Xoom in mid-July

Wednesday, June 27, 2012

How Software Installation & Package Managers Work On Linux


image

Installing software on Linux involves package managers and software repositories, not downloading and running .exe files from websites like on Windows. If you’re new to Linux, this can seem like a dramatic culture shift.
While you can compile and install everything yourself on Linux, package managers are designed to do all the work for you. Using a package manager makes installing and updating software easier than on Windows.

Linux vs. Windows

There are a wide variety of Linux distributions and a wide variety of package managers. Linux is built from open-source software, which means that each Linux distribution compiles its own software with its desired library versions and compilation options. Compiles Linux applications generally don’t run on every distribution – even if they could, installation would be hindered by competing package formats.If you locate a Linux application’s website, you’ll likely see a variety of download links for different package formats and Linux distributions – assuming the application’s website provides pre-compiled versions at all. The application may tell you to download the source code and compile it yourself.

Software Repositories

Linux users don’t normally download and install applications from the applications’ websites, like Windows users do. Instead, each Linux distribution hosts their own software repositories. These repositories contain software packages specially compiled for each Linux distribution and version. For example, if you’re using Ubuntu 12.04, the repositories you use contain packages specially compiled for Ubuntu 12.04. A Fedora user uses a repository full of packages specially compiled for their version of Fedora.

Package Managers

Think of a package manager like a mobile app store – except they were around long before app stores. Tell the package manager to install software and it will automatically download the appropriate package from its configured software repositories, install it, and set it up – all without you having to click through wizards or hunt down .exe files on websites. When an update is released, your package manager notices and downloads the appropriate update. Unlike on Windows, where each application must have its own updater to receive automatic updates, the package manager handles updates for all installed software — assuming they were installed from the software repositories.

What’s a Package?

Unlike on Windows, where applications come in .exe installer files that can do anything they like to the system, Linux uses special package formats. There are a variety of package types – most notably DEB on Debian and Ubuntu and RPM on Fedora, Red Hat, and others. These packages are essentially archives containing a list of files. The package manager opens the archive and installs the files to the location the package specifies. The package manager remains aware of which files belong to which packages – when you uninstall a package, the package manager knows exactly which files on the system belong to it. Windows has no idea what files belong to an installed application – it lets application installers manage installation and uninstallation themselves.
Packages can also contain scripts that run when the package is installed and removed, although these are generally used for system setup and not moving files to arbitrary locations.

Installing Software on Linux

To install software on Linux, open your package manager, search for the software, and tell the package manager to install it. Your package manager will do the rest. Linux distributions often offer a variety of frontends to the package manager. For example, on Ubuntu, the Ubuntu Software Center, Update Manager, Synaptic application, and apt-get command all use apt-get and dpkg to download and install DEB packages. You can use any utility you like – they just provide different interfaces. You’ll generally find a simple, graphical package manager in your Linux distribution’s menus.

Update Delays

One thing new Linux users often notice with package managers and repositories is a delay before new software versions reach their systems. For example, when a new version of Mozilla Firefox is released, Windows and Mac users will acquire it from Mozilla. On Linux, your Linux distribution must package the new version and push it out as an update. If you open Firefox’s preferences window on Linux, you’ll note that Firefox has no ability to automatically update itself (assuming you’re using the version of Firefox from your Linux distribution’s repositories).
You can also download and install the application yourself – for example, downloading Firefox directly from Mozilla — but this may require compiling and installing the software from source and removes the benefits of package managers, such as automatic, centralized security updates.
While new versions of Firefox are a priority because they contain security updates, other applications may not be delivered as quickly. For example, a major new version of the LibreOffice office suite may not ever be released as an update for the current version of your Linux distribution. To avoid potential instability and allow time for testing, this version may not be available until the next major release of your Linux distribution – for example, Ubuntu 12.10 – when it becomes the default version in the distribution’s software repositories.
To fix this problem, some Linux distributions, such as Arch Linux, offer “rolling release cycles,” where new versions of software are pushed into the main software repositories. This may cause problems – while you may want new versions of desktop applications, you probably don’t care about new versions of low-level system utilities, which could potentially introduce instability.
Ubuntu offers the backports repository to bring newer versions of significant packages to older distributions, although not all new versions make it into the backports repository.

Other Repositories

While Linux distributions ship with their own repositories pre-configured, you can also add other repositories to your system. Once you have, you can install software repositories from that repository and receive updates from it using your package manager. The repository you add must be designed for your Linux distribution and package manager.
For example, Ubuntu offers a wide variety of personal package archives (PPAs), which contain software compiled by individuals and teams. Ubuntu doesn’t vouch for the stability or security of the packages in these repositories, but you can add PPAs from trusted individuals to download packages not yet in Ubuntu’s repository – or download newer versions of existing packages.
Some third-party applications also use their own software repositories. For example, when you install Google Chrome on Ubuntu, it adds its own apt repository to your system. This ensures you receive updates to Google Chrome through Ubuntu’s Update Manager and standard software installation tools.

Tuesday, June 26, 2012

Automatically Lock or Logoff Your Windows Computer



Auto logoff
arrow Windows Windows only arrow
Windows can be configured to lock your computer after the screen saver kicks in, which means when you return you’ll need to login again. The security this offers is nice but it’s not very customizable, and one such example is that you can’t easily the screen to turn off and lock the computer at the same time. That means you might be wasting electricity powering the screen while you’re not even sitting in front of the computer.
Using the free and portable Auto Lock app you can change that. As you can see in the screenshot above you can change a lot of the options relating to what happens when your computer has been idle for a certain amount of time. With it you can have the screen turn off at the same time your PC gets locked, or you can configure it to logoff, restart, or shutdown the machine.
There’s also the option to mute system sounds, which you may be wondering why you’d use an option like that. One of the reasons I thought about is that if you were going to have the app shutdown your computer you could have this mute the system sounds first to ensure that it performs a silent shutdown. So give Auto Lock a try if this sounds like something you’ve been looking for.
Auto Lock Homepage (Windows only; Freeware)

Finally CPU Inside Keyboard...



Google Management


Co-founders Larry Page, president of Products, and Sergey Brin, president of Technology, brought Google to life in September 1998. Since then, the company has grown to more than 10,000 employees worldwide, with a management team that represents some of the most experienced technology professionals in the industry. Eric Schmidt joined Google as chairman and chief executive officer in 2001.

Board of Directors
Operating Committee
Key executives by function:
  • Kent Walker, Vice President & General Counsel
  • David Lawee, Vice President, Corporate Development
  • Megan Smith, Vice President, New Business Development, and General Manager, Google.org
  • Dr. Larry Brilliant, Chief Philanthropy Evangelist, Google.org
  • Megan Smith, Vice President, New Business Development, and General Manager, Google.org

The Linux Directory Structure Explained


image

If you’re coming from Windows, the Linux file system structure can seem particularly alien. The C:\ drive and drive letters are gone, replaced by a / and cryptic-sounding directories, most of which have three letter names.
The Filesystem Hierarchy Standard (FHS) defines the structure of file systems on Linux and other UNIX-like operating systems. However, Linux file systems also contain some directories that aren’t yet defined by the standard.

/ – The Root Directory

Everything on your Linux system is located under the / directory, known as the root directory. You can think of the / directory as being similar to the C:\ directory on Windows – but this isn’t strictly true, as Linux doesn’t have drive letters. While another partition would be located at D:\ on Windows, this other partition would appear in another folder under / on Linux.

/bin – Essential User Binaries

The /bin directory contains the essential user binaries (programs) that must be present when the system is mounted in single-user mode. Applications such as Firefox are stored in /usr/bin, while important system programs and utilities such as the bash shell are located in /bin. The /usr directory may be stored on another partition – placing these files in the /bin directory ensures the system will have these important utilities even if no other file systems are mounted. The /sbin directory is similar – it contains essential system administration binaries.

/boot – Static Boot Files

The /boot directory contains the files needed to boot the system – for example, the GRUB boot loader’s files and your Linux kernels are stored here. The boot loader’s configuration files aren’t located here, though – they’re in /etc with the other configuration files.

/cdrom – Historical Mount Point for CD-ROMs

The /cdrom directory isn’t part of the FHS standard, but you’ll still find it on Ubuntu and other operating systems. It’s a temporary location for CD-ROMs inserted in the system. However, the standard location for temporary media is inside the /media directory.

/dev – Device Files

Linux exposes devices as files, and the /dev directory contains a number of special files that represent devices. These are not actual files as we know them, but they appear as files – for example, /dev/sda represents the first SATA drive in the system. If you wanted to partition it, you could start a partition editor and tell it to edit /dev/sda.
This directory also contains pseudo-devices, which are virtual devices that don’t actually correspond to hardware. For example, /dev/random produces random numbers. /dev/null is a special device that produces no output and automatically discards all input – when you pipe the output of a command to /dev/null, you discard it.

/etc – Configuration Files

The /etc directory contains configuration files, which can generally be edited by hand in a text editor. Note that the /etc/ directory contains system-wide configuration files – user-specific configuration files are located in each user’s home directory.

/home – Home Folders

The /home directory contains a home folder for each user. For example, if your user name is bob, you have a home folder located at /home/bob. This home folder contains the user’s data files and user-specific configuration files. Each user only has write access to their own home folder and must obtain elevated permissions (become the root user) to modify other files on the system.

/lib – Essential Shared Libraries

The /lib directory contains libraries needed by the essential binaries in the /bin and /sbin folder. Libraries needed by the binaries in the /usr/bin folder are located in /usr/lib.

/lost+found – Recovered Files

Each Linux file system has a lost+found directory. If the file system crashes, a file system check will be performed at next boot. Any corrupted files found will be placed in the lost+found directory, so you can attempt to recover as much data as possible.

/media – Removable Media

The /media directory contains subdirectories where removable media devices inserted into the computer are mounted. For example, when you insert a CD into your Linux system, a directory will automatically be created inside the /media directory. You can access the contents of the CD inside this directory.

/mnt – Temporary Mount Points

Historically speaking, the /mnt directory is where system administrators mounted temporary file systems while using them. For example, if you’re mounting a Windows partition to perform some file recovery operations, you might mount it at /mnt/windows. However, you can mount other file systems anywhere on the system.

/opt – Optional Packages

The /opt directory contains subdirectories for optional software packages. It’s commonly used by proprietary software that doesn’t obey the standard file system hierarchy – for example, a proprietary program might dump its files in /opt/application when you install it.

/proc – Kernel & Process Files

The /proc directory similar to the /dev directory because it doesn’t contain standard files. It contains special files that represent system and process information.

/root – Root Home Directory

The /root directory is the home directory of the root user. Instead of being located at /home/root, it’s located at /root. This is distinct from /, which is the system root directory.

/run – Application State Files

The /run directory is fairly new, and gives applications a standard place to store transient files they require like sockets and process IDs. These files can’t be stored in /tmp because files in /tmp may be deleted.

/sbin – System Administration Binaries

The /sbin directory is similar to the /bin directory. It contains essential binaries that are generally intended to be run by the root user for system administration.

/selinux – SELinux Virtual File System

If your Linux distribution uses SELinux for security (Fedora and Red Hat, for example), the /selinux directory contains special files used by SELinux. It’s similar to /proc. Ubuntu doesn’t use SELinux, so the presence of this folder on Ubuntu appears to be a bug.

/srv – Service Data

The /srv directory contains “data for services provided by the system.” If you were using the Apache HTTP server to serve a website, you’d likely store your website’s files in a directory inside the /srv directory.

/tmp – Temporary Files

Applications store temporary files in the /tmp directory. These files are generally deleted whenever your system is restarted and may be deleted at any time by utilities such as tmpwatch.

/usr – User Binaries & Read-Only Data

The /usr directory contains applications and files used by users, as opposed to applications and files used by the system. For example, non-essential applications are located inside the /usr/bin directory instead of the /bin directory and non-essential system administration binaries are located in the /usr/sbin directory instead of the /sbin directory. Libraries for each are located inside the /usr/lib directory. The /usr directory also contains other directories – for example, architecture-independent files like graphics are located in /usr/share.
The /usr/local directory is where locally compiled applications install to by default – this prevents them from mucking up the rest of the system.

/var – Variable Data Files

The /var directory is the writable counterpart to the /usr directory, which must be read-only in normal operation. Log files and everything else that would normally be written to /usr during normal operation are written to the /var directory. For example, you’ll find log files in /var/log.

Tuesday, June 19, 2012

8 Ways to Tweak and Configure Sudo on Ubuntu


image

Like most things on Linux, the sudo command is very configurable. You can have sudo run specific commands without asking for a password, restrict specific users to only approved commands, log commands run with sudo, and more.
The sudo command’s behavior is controlled by the /etc/sudoers file on your system. This command must be edited with the visudo command, which performs syntax-checking to ensure you don’t accidentally break the file.

Specify Users With Sudo Permissions

The user account you create while installing Ubuntu is marked as an Administrator account, which means it can use sudo. Any additional user accounts you create after installation can be either Administrator or Standard user accounts – Standard user accounts don’t have sudo permissions.
You can control user account types graphically from Ubuntu’s User Accounts tool. To open it, click your user name on the panel and select User Accounts or search for User Accounts in the dash.

Make Sudo Forget Your Password

By default, sudo remembers your password for 15 minutes after you type it. This is why you only have to type your password once when executing multiple commands with sudo in quick succession. If you’re about to let someone else use your computer and you want sudo to ask for the password when it runs next, execute the following command and sudo will forget your password:
sudo –k

Always Ask For a Password

If you’d rather be prompted each time you use sudo – for example, if other people regularly have access to your computer — you can disable the password-remembering behavior entirely.
This setting, like other sudo settings, is contained in the /etc/sudoers file. Run the visudo command in a terminal to open the file for editing:
sudo visudo
In spite of its name, this command defaults to the new-user-friendly nano editor instead of the traditional vi editor on Ubuntu.
Add the following line below the other Defaults lines in the file:
Defaults timestamp_timeout=0
Press Ctrl+O to save the file, and then press Ctrl+X to close Nano. Sudo will now always prompt you for a password.

Change the Password Timeout

To set a different password timeout – either a longer one like 30 minutes or a shorter one like 5 minutes – follow the steps above but use a different value for timestamp_timeout. The number corresponds to the number of minutes sudo will remember your password for. To have sudo remember your password for 5 minutes, add the following line:
Default timestamp_timeout=5

Never Ask for a Password

You can also have sudo never ask for a password – as long as you’re logged in, every command you prefix with sudo will run with root permissions. To do this, add the following line to your sudoers file, where username is your username:
username ALL=(ALL) NOPASSWD: ALL
You can also change the %sudo line – that is, the line that allows all users in the sudo group (also known as Administrator users) to use sudo – to have all Administrator users not require passwords:
%sudo ALL=(ALL:ALL) NOPASSWD:ALL

Run Specific Commands Without a Password

You can also specify specific commands that will never require a password when run with sudo. Instead of using “ALL” after NOPASSWD above, specify the location of the commands. For example, the following line will allow your user account to run the apt-get and shutdown commands without a password.
username ALL=(ALL) NOPASSWD: /usr/bin/apt-get,/sbin/shutdown
This can be particularly useful when running specific commands with sudo in a script.

Allow a User to Run Only Specific Commands

While you can blacklist specific commands and prevent users from running them with sudo, this isn’t very effective. For example, you could specify that a user account not be able to run the shutdown command with sudo. But that user account could run the cp command with sudo, create a copy of the shutdown command, and shut down the system using the copy.
A more effective way is to whitelist specific commands. For example, you could give a Standard user account permission to use the apt-get and shutdown commands, but no more. To do so, add the following line, where standarduser is the user’s username:
standarduser ALL=/usr/bin/apt-get,/sbin/shutdown
The following command will tell us what commands the user can run with sudo:
sudo -U standarduser –l

Logging Sudo Access

You can log all sudo access by adding the following line. /var/log/sudo is just an example; you can use any log file location you like.
Defaults logfile=/var/log/sudo
View the contents of the log file with a command like this one:
sudo cat /var/log/sudo
Bear in mind that, if a user has unrestricted sudo access, that user has the ability to delete or modify the contents of this file. A user could also access a root prompt with sudo and run commands that wouldn’t be logged. The logging feature is most useful when coupled with user accounts that have restricted access to a subset of system commands.

Saturday, June 16, 2012

How to Install a WAMP Server: Windows, Apache, MySQL, and PHP



Wamp windows apache mysql php
arrow Windows Windows only arrow
If you want to play around with PHP and MySQL the chances are pretty good that you’ve heard of LAMP, which stands for Linux, Apache, MySQL, and PHP. There are ways to get this setup running with very little work, but if you’re already running Windows there are WAMP packages available that make it just as easy, if not easier.
A great example of this is The Uniform Server. All you have to do to get Apache, MySQL, and PHP running on your Windows machine is download and extract the files. There are executables at the root of the extracted folder allowing you to start this as a program or as a service, and once you start it up a simple click of theStart Both button in the GUI will give you a working WAMP setup.
What is really cool about this is that all of the necessary files are all self-contained in a single folder. That means if you really want to you can throw them on a USB drive and have a portable web server that you can start up on just about any Windows machine. When it comes to web development work that kind of versatility is pretty awesome.
At the time I tried this out I was using version 8.5.4 of The Uniform Server, which runs the following:
  • Apache 2.4.2
  • MySQL 5.5.24-community
  • PHP 5.4.3
  • phpMyAdmin 3.5.1
  • eAccelerator 1.0-svn427
  • APC 3.1.10
  • UniController
  • OpenSSL 1.0.1
  • Go-Pear 1.1.6
  • msmtp 1.4.27 – Mail client for PHP 
  • Cron – Scheduler
  • DtDNS – IP address updater
  • db_backup – Database back-up
  • ActivePerl via Installer
Don’t forget to checkout the plug-ins page if you’re looking to do even more with your WAMP set up. They have one plug-in there that I really like called The UniTray that will let you manage the server from the Windows System Tray.
The Uniform Server (Windows only; Freeware)