Sponsored Content
Top Forums UNIX for Beginners Questions & Answers Compare two directory and find differents Post 303045817 by RudiC on Tuesday 14th of April 2020 04:30:56 AM
Old 04-14-2020
That was not mentioned in your OP. Try
Code:
find SRC -iname "*.doc*" | while read FP; do FB="${FP%.*}"; [ ! -f "${FB/SRC/DST}.pdf" ] && echo "$FP"; done
SRC/D2/File6.doc
SRC/D2/File2.docx
SRC/D1/File6.doc
SRC/D1/File2.docx
SRC/File6.doc
SRC/File2.docx

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Directory compare script

Hello, I am looking for a script, or pointer to an approach to creating a script, that will compare two versions of a codebase and output a third directory structure containing only the files that differ between the two. I use diff quite often, but it will only create patch files (AFAIK). Does... (3 Replies)
Discussion started by: jwilliams108
3 Replies

2. Shell Programming and Scripting

Script That Can navigate to 3 differents directory & remove files under them

Hi I am Trying to Write a script that can goto 4 different directorys on the server & remove the Files older then 30 days ?? /logs logs1 logs2 logs3 Now I need to remove files under logs1 logs2 logs3 which are older then 30 days whose name stat 'sit' , 'mig','bld' . in... (3 Replies)
Discussion started by: Beginner123
3 Replies

3. Shell Programming and Scripting

How i can obtain differents data on a single pass?

#!/bin/bash for i in `ls -c1 /usr/share/applications` do #name=`cat /usr/share/applications/$i | grep ^Name= | cut -d = -f2` #categories=`cat /usr/share/applications/$i | grep ^Categories= | sed 's/;/=/g' | cut -d = -f2` name=$(grep ^Name= /usr/share/applications/$i | cut -d = -f2)... (12 Replies)
Discussion started by: alexscript
12 Replies

4. Shell Programming and Scripting

Compare new version of two directory

How to compare new version exist of two path directory. for e.g., path1 - /user/path/test/ path2 - /user/path/score/ If its exist new version then copy that new version into the first path directroy. How will do this. (3 Replies)
Discussion started by: roy1912
3 Replies

5. Shell Programming and Scripting

Extract sequences of bytes from binary for differents blocks

Hello to all, I would like to search sequences of bytes inside big binary file. The bin file contains blocks of information, each block begins is estructured as follow: 1- Each block begins with the hex 32 (1 byte) and ends with FF. After the FF of the last block, it follows 33. 2- Next... (59 Replies)
Discussion started by: Ophiuchus
59 Replies

6. Shell Programming and Scripting

Find every directory named XYZ under the DVLP directory

I only want to find files under each branch of the directory tree inside directories named XYZ and there are multiple XYZ directories? (7 Replies)
Discussion started by: emc^24sho
7 Replies

7. Programming

Query SQL get two values differents from the same columns

Hi, I have 2 different values in the same column and two different values in other column Query 1 ins name value 1 Test 12345 1 TestV1 12/10/2014 8 Test 85435 8 TestV1 11/11/2005 9 Test 42232 9 TestV1 19/10/2000 6 Test 54321... (6 Replies)
Discussion started by: faka
6 Replies

8. Shell Programming and Scripting

awk - matching on 2 columns for differents lines

Given this file (I separated them in block to make my explanation clearer): 92157768877;Sof_deme_Fort_Email_am_%yyyy%%mm%%dd%;EMAIL;20/02/2015;1;0;0 92157768877;Sof_trav_Fort_Email_am_%yyyy%%mm%%dd%;EMAIL;20/02/2015;1;0;0 91231838895;Sof_deme_faible_Email_am;EMAIL;26/01/2015;1 0;0... (1 Reply)
Discussion started by: Andy_K
1 Replies

9. Shell Programming and Scripting

Compare directory dates

hi, I need to know if a specific directory exists in a folder named after the date of yesterday (02/06/2015) The problem is simple but not how to do it. :confused:i= date -d "yesterday" '%Y-%m-%d' <- the format of directory is 2015-06-02 if in /var/logroot/index exist directory whit... (4 Replies)
Discussion started by: tmeto
4 Replies

10. UNIX for Beginners Questions & Answers

How to find and get a file in an entire directory with an excluded directory specified?

How to get a file 'zlib.h' in an entire directory with an excluded directory specified lives under that starting directory by using find command, as it failed on: $ find . -name 'zlib.h' -a -ipath 'CHROME.TMP' -prune -o -print it'll just list entirely up (2 Replies)
Discussion started by: abdulbadii
2 Replies
pstotext(1)						      General Commands Manual						       pstotext(1)

NAME
pstotext - extract ASCII text from a PostScript or PDF file SYNTAX
pstotext [option|pathname]... where option includes: -cork -landscape -landscapeOther -portrait - -output file -gs command -debug -bboxes DESCRIPTION
pstotext reads one or more PostScript or PDF files, and writes to standard output a representation of the plain text that would be dis- played if the PostScript file were printed. As is described in the DETAILS section below, this representation is only an approximation. Nevertheless, it is often useful for information retrieval (e.g., running grep(1) or building a full-text index) or to recover the text from a PostScript file whose source you have lost. pstotext calls Ghostscript, and requires Aladdin Ghostscript version 3.51 or newer. Ghostscript must be invokable on the current search path as gs. Alternatively, you can use the -gs option to specify the command (pathname and options) to run Ghostscript. For example, on Windows you might use -gs "c:gsgswin32c.exe -Ic:gs;c:gsfonts". pstotext reads and processes its command line from left to right, ignoring the case of options. When it encounters a pathname, it opens the file and expects to find a PostScript job or PDF document to process. The option - means to read and process a PostScript job from standard input. If no - or pathname arguments are encountered, pstotext reads a PostScript job from standard input. (PDF documents require random access, hence cannot be read from standard input.) You can use the -output option to specify an output file (remember to invoke it before the input file); otherwise pstotext writes to standard output. The option -cork is only relevant for PostScript files produced by dvips from TeX or LaTeX documents; it tells pstotext to use the Cork encoding (known as T1 in LaTeX) rather than the old TeX text encoding (known as OT1 in LaTeX). Unfortunately files produced by dvips don't distinguish which font encodings were used. The options -landscape and -landscapeOther should be used for documents that must be rotated 90 degrees clockwise or counterclockwise, respectively, in order to be readable. The options -debug and -bboxes are mostly of use for the maintainers of pstotext. -debug shows Ghostscript output and error messages. -bboxes outputs one word per line with bounding box information. DETAILS
pstotext does its work by telling Ghostscript to load a PostScript library that causes it to write to its standard output information about each string rendered by a PostScript job or PDF document. This information includes the characters of the string, and enough additional information to approximate the string's bounding rectangle. pstotext post-processes this information and outputs a sequence of words delimited by space, newline, and formfeed. pstotext outputs words in the same sequence as they are rendered by the document. This usually, but not always, follows the order that a human would read the words on a page. Within this sequence, words are separated by either space or newline depending on whether or not they fall on the same line. Each page is terminated with a formfeed. If you use the incorrect option from the set {-portrait, -landscape, -landscapeOther}, pstotext is likely to substitute newline for space. A PostScript job or PDF document often renders one word as several strings in order to get correct spacing between particular pairs of characters. pstotext does its best to assemble these strings back into words, using a simple heuristic: strings separated by a distance of less than 0.3 times the minimum of the average character widths in the two strings are considered to be part of the same word. Note that this typically causes leading and trailing punctuation characters to be included with a word. The PostScript language provides a flexible encoding scheme by which character codes in strings select specific characters (symbols), so a PostScript job is free to use any character code. On the other hand, pstotext always translates to the ISO 8859-1 (Latin-1) character code, which is an extension to ASCII covering most of the Western European languages. When a character isn't present in ISO 8859-1, psto- text uses a sequence of characters, e.g., "---" for em dash or "A226" for Abreve. pstotext can be fooled by a font whose Encoding vector doesn't follow Adobe's conventions, but it contains heuristics allowing it to handle a wide variety of misbehaving fonts. (pstotext no longer translates hyphen (255) to minus (55).) AUTHOR
Andrew Birrell (PostScript libraries), Paul McJones (application), Russell Lang (Windows and OS/2 adaptation), and Hunter Goatley (VMS adaptation). SEE ALSO
pstotext incorporates technology originally developed for the Virtual Paper project at SRC; see http://www.research.digital.com/SRC/virtu- alpaper/. As mentioned above, pstotext invokes Ghostscript. See gs(1) or http://www.cs.wisc.edu/~ghost/. COPYRIGHT
Copyright 1995-8 Digital Equipment Corporation. Distributed only by permission. See file /usr/share/doc/pstotext/copyright for details. Last modified on Sat Feb 5 21:00:00 AEST 2000 by rjl modified on Fri Jun 5 14:02:37 PDT 1998 by mcjones modified on Wed Jun 7 17:47:56 PDT 1995 by birrell This file was generated automatically by mtex software; see the mtex home page at http://www.research.digital.com/SRC/mtex/. pstotext(1)
All times are GMT -4. The time now is 12:59 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy