Copy contents of a directory

Thursday, December 27, 2012

If you need to create a batch file in Windows to copy the content of a directory including its subdirectory, you can use 'xcopy'.

xcopy /s c:\source d:\target

These are some of the options you can use with the command

  • /s/e - recursive copy, including copying empty directories.
  • /v - add this to verify the copy against the original. slower, but for the paranoid.
  • /h - copy system and hidden files.
  • /k - copy read-only attributes along with files. otherwise, all files become read-write.
  • /x - if you care about permissions, you might want /o or /x.
  • /y - don't prompt before overwriting existing files.
  • /z - if you think the copy might fail and you want to restart it, use this. It places a marker on each file as it copies, so you can rerun the xcopy command to pick up from where it left off.

Read more...

How to get post total for each author for blogspot

Wednesday, March 28, 2012

Sometimes, you have a blog with several authors and you might need to keep tract on their total post. So, this is how I do it

I create a simple php file to do that.

$url = "http:///feeds/posts/default?alt=rss&redirect=false&max-results=10000"
$str = file_get_contents($url)

echo "NickName (".substr_count($str, (authorName)').");
echo "NickName2 (".substr_count($str, (authorName2)').");

Read more...

How To Log Every Query That Goes Through MySQL

Ever wonder the easiest way to log each of your query in mysql? Here's the simplest way where you don't need to restart mysql everytime.


1. Open your command prompt window.

2. Browser to you mysql folder.
Eg :

cd Program Files\MySQL\MYSQL5.1\bin

3. Log into your mysql using cmd
Eg :
mysql -u root -p
You will be asked for your password, so enter your password

4. Now execute this statement..
SET GLOBAL log_output = 'TABLE';
then
SET GLOBAL general_log = 'ON';

And you're done. Check your general_log table in the 'mysql' database.

After certain period of time, you will realized that your general_log table is getting bigger and it will consume some time just to load. And btw, you can't delete the content just like that. So here's how to overcome that.

1. Follow step 1 and 2 as above.

2. Choose 'mysql' db by running this cmd..
USE mysql

3.Create a new table similar to general_log structure using this cmd
create table general_log_dummy like general_log

4. rename and replace the tables
rename table general_log to general_log_old, general_log_dummy to general_log

Now you have a new general_log table and you can delete the old table.

Read more...

Wednesday, February 29, 2012


Meet our future computer...

TRONDHEIM, Norway and BARCELONA, Spain -26 Feb. 2012 @ Showstoppers MWC – FXI Technologies, Inc. today introduced the launch of cstick.com, a community website and technical forum where Cotton Candy development units are immediately available for pre-order.

“The world is anxiously awaiting Cotton Candy’s release,” said Borgar Ljosland, CEO and founder of FXI. “We’ve had interest in the any screen computer for everything from portable set top box gaming and entertainment to mobile any screen computing, in addition to a host of specialized medical, automotive and other applications. The size, raw horsepower and combined HDMI, USB and MicroUSB connectivity bring unprecedented flexibility to the portable market. ”

On display at this week’s Mobile World Congress tradeshow in the Innovation Norway Booth (Hall 2.0-2A67), Cotton Candy is the world’s first any screen cloud computer, weighing only 21 grams. It’s unique architecture will allow the device to serve as an ideal companion to smartphones, tablets, notebook PCs and Macs as well as will add smart capabilities to existing displays, set top boxes and game consoles.

Specifications include an ARM® Cortex™-A9 (1GHz) CPU from Samsung, an ARM Mali™-400 MP (Quad-core, 1.2GHz) GPU, Wi-Fi and Bluetooth, HDMI output and the Android operating system. It decodes MPEG-4, H.264 and other video formats and display HD graphics on any HDMI equipped screen. Operating systems supported to date include Android Gingerbread and Ice Cream Sandwich as well as Ubuntu. On-screen content can be controlled a wide variety of ways – wirelessly using smartphones with an app, Bluetooth peripherals like mice and RF remote controls; or by leveraging a notebook’s integrated keyboard and touchpad.

To join the Cotton Candy development community, visit www.cstick.com.

About FXI
FXI Technologies (www.fxitech.com) is a Norway-based hardware and software startup dedicated to making the world of digital screens smart and personal.

####
This article was originally published in forum thread: Fxi launches cotton candy developer site, takes pre-orders started by Borgar Ljosland View original post

Read more...
Technology blogs Blog Directory

  © Blogger template Noblarum by Ourblogtemplates.com 2009

Back to TOP