WP-CLI is the command line interface for WordPress. If you have not setup WP-CLI yet, see steps to setup WP-CLI.
There is tab completions feature which is generally missed in the installation process. Here are the easy few steps to add tab completions for the WP-CLI. I am using Ubuntu here for example. But it would be similar for UNIX environment.
You need to have
bash file for setting up autocomplete in the terminal. WP-CLI has already provided bash file. You can download it from Github repo of WP-CLI.
Put that downloaded
wp-completion.bash file under the folder you like. Say you keep under
completions in your Home directory.
Now, open your
.bashrc file with your favorite text editor.
In that file, put code to source your completion file. Syntax will be similar to:
In our example, it would be:
Save your file and close it. Now you need to source your bashrc file to activate your new code for the terminal.
Then restart the terminal.
Its that simple, no? But it will be very handy to use WP-CLI. I am sure you will love it.
Sublime Text is the most popular text / source code editor widely used in programming. Although it is a proprietary software, there are lots of free and community build plugins which can be used to extend the feature of Sublime Text. If you are not already fallen in love with Sublime Text, they you must give try.
Gist is a simple way to share snippets and pastes with others. This is one awesome service provided by Github. It allows you to store code snippets for later use, you can have as many private gists as you need and you can group multiple gist files under a single gist.
If you frequently use Gist then there is a Sublime Text plugin which helps you to use it easy way. You can manually install this Sublime Text plugin from this Gist github repository.Or you can install it through Package Manager.
Generate Access Token
You will need Access Token for using Gist in Sublime text.
- Open up github site.
- Go to Account Settings -> Applications
- Click “Generate new token” under “Personal access tokens”
- Enter some meaningful name in “Token description”
- Under “Select scopes”, select gist
Setting up in Sublime Text
- Open Sublime Text
- Go to Preferences -> Package Settings -> Gist -> Settings – User
Do you want to earn money? Just receive your call as you always do. You can earn 1 cent in every call. But you need Android smartphone for this scheme. Shiran Technologies Pvt. Ltd. has developed ‘CashOnAD‘ for this type of scheme.
Video media advertisement experience has never been available to mobile phones. Considering the growth in smartphone users, CashOnAd provides a unique platform to reach mass market by publishing engaging advertisements and benefits the customer with 1 cent on each call received.
Download CachOnAd from playstore of Google.
Official Home page : http://www.cashonad.com/
Currently CashonAD is only available in Android smartphone. According to officials of Shiran Technologies, it will also available in iOS version. Apple users will have to wait sometime for using CashonAD in their phone.
After installing CASHonAD application in your android smartphone, you need to create an account. You can create account using Facebook. Also you can register using your email address.
Steps to earn cash
- Ad should be viewed at least for 6 seconds in each incoming calls.
- It is recommended to sync balance at least once in 24 hours via internet to avoid loss of balance.
- Checkout your amount through your preferred payment gateway. Currently two methods are available ; PayPal and eSewa
If you are using git in Linux then you might have hit command ‘git status’ to find out in which branch are we currently on, whether there are any changed contents or any uncommitted changes. Wouldn’t be nice if we can get those git information easily so that we need not hit that command frequently. ‘vcprompt’ is the solution here. You can easily integrate vcprompt in bash prompt so that we can see git information from the prompt itself. Lets discuss some steps to integrate vcprompt in bash. I am using Ubuntu 12.10 here. It should also work in other similar Linux variations.
vcprompt is a script to show version control information in the command prompt. This script is written by djl. vcprompt is heavily inspired by Greg Ward’s original implementation in C.
Requirements: Python 2.4 or later
You can check Python version from following command.
If curl is not installed in your systemm then you have to install curl first.
sudo apt-get install curl
How to do?
Download vcprompt script and make it executable.
sudo curl -sL https://github.com/djl/vcprompt/raw/master/bin/vcprompt > ~/bin/vcprompt
sudo chmod 755 ~/bin/vcprompt
Now we have to setup bash to use vcprompt.For this you we need to modify .bashrc file
Copy the following code and paste it in the end of the file.
PS1='n�33[0;34mu@h:�33[0;31mw �33[01;35m $(vcprompt -f '[%b%m%u%a]')�33[00m n> '
Save the file and close the editor. Enter following command.
Hmm…now you get nice looking prompt. If you are in the git working folder then you will see current branch and other git informations.
Dont forget to check README file of vcprompt for more customization options.