RSS Subscription
Linux Howtos & Tutorials

Enter your email:

Delivered by


NOTE:New tutorials are from LinuxCareer.com

Poll

Do you own or wish to have iPhone?
 


Linux eBooks FREE Download
A guide to programming Linux kernel modules
Introduction to Linux - A Hands on Guide
A Newbie's Getting Started Guide to Linux

Linux from Scratch - Create Your Own Linux System - Free eBook

Linux: The Hacking Solution (v.3.0)

SQLite 3 with PHP Essential Training – Free Video Training Tutorials

This guide will introduce you to the world of GNU/Linux

The GNU/Linux Advanced Administration

A Complete Beginner's Manual for Ubuntu 10.04 (Lucid Lynx)

Advanced Bash-Scripting Guide

Set up, maintain, and secure a small office email server

Partner Linux Sites:
How-To.LinuxCareer.com
Jobs.LinuxCareer.com
TuxMachines
Monsterb
LinuxBloggers
AdamsInfo
LinuxScrew
All For Linux

Remove an apostrophe from a filename

Filename with a apostrophe / single quote in its file name can cause a lot of problems when used with a bash script or used on a command line. The following command will remove all apostrophes from all files located in a current working directory:

for f in *; do mv "$f" `echo $f | sed 's/\x27//g'`; done

If you with to replace a apostrophe with X you can use a following command:

for f in *; do mv "$f" `echo $f | sed 's/\x27/X/g'`; done

Share this linux post:

Submit Remove an apostrophe from a filename in Delicious Submit Remove an apostrophe from a filename in Digg Submit Remove an apostrophe from a filename in FaceBook Submit Remove an apostrophe from a filename in Google Bookmarks Submit Remove an apostrophe from a filename in Stumbleupon Submit Remove an apostrophe from a filename in Technorati Submit Remove an apostrophe from a filename in Twitter
 
Comments for this page are closed !!!
Please visit our new Linux Forum for additional help or discussion.


Linux eBooks FREE Download