The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
csplit issue uandme2k2 Shell Programming and Scripting 1 10-06-2009 02:11 PM
Problem with csplit shreekrishnagd Shell Programming and Scripting 4 02-06-2009 11:26 AM
prefix suffix to each argument tostay2003 Shell Programming and Scripting 1 01-02-2009 05:54 PM
How to rename multiple files with a common suffix er_ashu UNIX for Dummies Questions & Answers 1 09-28-2007 10:52 AM
csplit problem....please help me kumar1 Shell Programming and Scripting 2 10-07-2005 06:04 AM

Reply
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 6 Days Ago
MarioColuzzi MarioColuzzi is offline
Registered User
  
 

Join Date: Nov 2009
Posts: 1
Question csplit suffix-format: how to?

I am using GNU csplit to extract chapters from a big file into smaller files.

I want to use the -b option

-b, --suffix-format=FORMAT use sprintf FORMAT instead of %d

but I have failed so far.

1) All the generated files need to have a suffix .txt at the end
2) They have to look like something chapter.xxx.txt <-- .txt extremely important

Cheers
  #2 (permalink)  
Old 5 Days Ago
jim mcnamara jim mcnamara is offline Forum Staff  
...@...
  
 

Join Date: Feb 2004
Location: NM
Posts: 5,710
Code:
csplit -b "%04d.txt"  inputfilename
Sponsored Links
Reply

Bookmarks

Tags
csplit suffix-format

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 03:29 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0