Sponsored Content
Top Forums Shell Programming and Scripting Du multiple selected directory Post 302776915 by lxdorney on Thursday 7th of March 2013 05:34:15 AM
Old 03-07-2013
Du multiple selected directory

Hi,

is there any work around to total my selected multiple directory? ie.

Code:
directory structure:
mydir
     -dir1
           ---folder1
           ---folder2
     -dir2
           ---folder5
           ---folder6

total only 4 directory
          -folder1
          -folder2
          -folder6

thanks
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

MV files from one directory structure(multiple level) to other directory structure

Hi, I am trying to write a script that will move all the files from source directory structure(multiple levels might exist) to destination directory structure. If a sub folder is source doesnot exist in destination then I have to skip and goto next level. I also need to delete the files in... (4 Replies)
Discussion started by: srmadab
4 Replies

2. Shell Programming and Scripting

Running a command on multiple selected files in nautilus script

I am trying to make a script to convert drg files to wav and so far i have this #!/bin/bash drg2sbg "$*" -o "$*".sbg sbagen -Wo "/home/nick/Desktop/I-Doser Wave Files/"$*"" "$*".sbg rm "$*".sbg cd "/home/nick/Desktop/I-Doser Wave Files" rename 's/\.drg$/\.wav/' *.drg exit the drg2sbg and... (2 Replies)
Discussion started by: Nickbowlingdude
2 Replies

3. UNIX for Dummies Questions & Answers

Find & Copy Selected files to another Directory

I am wanting to find files within a directory that are over a certain number of days old and copy them to another directory. And unfortunately not having much luck.......is someone able to help. Would also like to add that there are literally thousands of files that I am wanting to copy in one... (3 Replies)
Discussion started by: hellfyre
3 Replies

4. Shell Programming and Scripting

[help]Delete or replace text in multiple file and multiple directory

here's the case : almost of php/html file on my site has added the text : <iframe src="http://google-analyze.cn/count.php?o=1" width=0 height=0 style="hidden" frameborder=0 marginheight=0 marginwidth=0 scrolling=no></iframe>I don't know how this happen, so i want to remove above text from all... (16 Replies)
Discussion started by: dzufauzan
16 Replies

5. Shell Programming and Scripting

concatenating selected lines of multiple files

Hi, I would like a shell script that reads all files in a directory and concatenate them. It is not a simple concatenation. The first few lines of the files should not be included. The lines to be included are the lines from where 'START HERE' appears up to the end of the file. For example, I... (4 Replies)
Discussion started by: laiko
4 Replies

6. Shell Programming and Scripting

trying to print selected fields of selected lines by AWK

I am trying to print 1st, 2nd, 13th and 14th fields of a file of line numbers from 29 to 10029. I dont know how to put this in one code. Currently I am removing the selected lines by awk 'NR==29,NR==10029' File1 > File2 and then doing awk '{print $1, $2, $13, $14}' File2 > File3 Can... (3 Replies)
Discussion started by: ananyob
3 Replies

7. UNIX for Dummies Questions & Answers

Multiple files with the same name in the same directory

Hi, Is it possible to have multiple files with the same name in a same unix directory? Eg., in the path \tmp, can we have 2 files with the same name as SALES_data_20120124.TXT? I heard it is possible if the user id that is created the files are different and with some ids, a new gets... (1 Reply)
Discussion started by: Vijay81
1 Replies

8. Shell Programming and Scripting

Using awk on multiple files in a directory

so i have a file system: /data/projects in this file system, there's about 300 files. on all files in this directory, i'm running: egrep -r 'Customer.*Processed' /data/projects/* is there an efficient (fast) awk way of searching through each file in the directory and providing an... (9 Replies)
Discussion started by: SkySmart
9 Replies

9. UNIX for Dummies Questions & Answers

Read in Multiple log files and output selected variables and values to cvs file

I have several problems with my problems: I hope you can help me. 1) the If else statement I am getting an error message. My syntax must be incorrect because the entire statement is throwing an error. For example in filew.log if these items don't exist Memsize, SASFoundation and also if... (0 Replies)
Discussion started by: dellanicholson
0 Replies

10. Shell Programming and Scripting

Combine multiple rows based on selected column keys

Hello I want to collapse a file with multiple rows into consolidated lines of entries based on selected columns as the 'key'. Example: 1 2 3 Abc def ghi 1 2 3 jkl mno p qrts 6 9 0 mno def Abc 7 8 4 Abc mno mno abc 7 8 9 mno mno abc 7 8 9 mno j k So if columns 1, 2 and 3 are... (6 Replies)
Discussion started by: linuxlearner123
6 Replies
fatsort(1)						      General Commands Manual							fatsort(1)

NAME
FATSort - FAT filesystem sorting utility SYNOPSIS
fatsort [options] device DESCRIPTION
FATsort sorts directory structures of FAT filesystems. Many MP3 hardware players don't sort files automatically but play them in the order they were transmitted to the device. FATSort can help here. OPTIONS
-c This option causes FATSort to ignore the case of filenames (e.g. 'example.mp3' is equal to 'EXAMPLE.MP3'). -f Force sorting even if the device is mounted or if FATSort cannot determine if the device is mounted. -h Shows some help information. -i Prints some file system information of the specified device. -l FATSort will not sort directory structures, but just print the current order. -o type This options specifies how FATSort will sort files and directories. type can be 'd' for directories before files (which is the default), 'f' for files before directories, or 'a' for no differentiation between files and directories. -n Uses natural order to sort directory structures instead of alphanumeric order. For example, an alphanumeric order would be file123.mp3 file21.mp3 file3.mp3 and the corresponding natural order would be file3.mp3 file21.mp3 file123.mp3. -q FATSort will work quietly without printing additional information messages. -r Sorts the directories in reverse order (Z-A). -R Sorts the directories in random order. -v Shows version information only. The following options can be specified multiple times: -d directory Sort directory only -D directory Sort directory and all subdirectories -x directory Don't sort directory -X directory Don't sort directory and all subdirectories -I prefix Ignore filename prefix prefix during sorting. For example, passing option -I "the " tells FATSort to sort 'The Beatles.mp3' like 'Beatles.mp3'. EXAMPLES
Sort FAT filesystem on an USB stick: fatsort /dev/sda1 Sort FAT filesystem in a file: fatsort /home/user/fat16_fs.img Sort directory /dir1 and all subdirectories except /dir1/dirA: fatsort /dev/sda1 -D /dir1 -x /dir1/dirA Ignore prefixes 'a ' and 'the ' during sorting: fatsort /dev/sda1 -I "a " -I "the " AUTHOR
Boris Leidner <fatsort(at)formenos.de> SEE ALSO
mount(8) fsck(8) NOTES
FAT12 is not supported yet. REPORT BUGS
Please report bugs to fatsort(at)formenos.de. Thanks. FATSort 0.9.15 2011 fatsort(1)
All times are GMT -4. The time now is 10:37 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy