Sponsored Content
Top Forums Shell Programming and Scripting SED (or other) upper to lowercase, with first letter of first word in each sentence uppercase Post 302652779 by dockline on Thursday 7th of June 2012 05:37:28 PM
Old 06-07-2012
This data is updated several times a day, every day, so it must be automated. I can program SED to replace often used words and phrases with the right capitalization. Words like ATLC and Atlantic and Gulf, for example, are taken care of by this.

The problem is the first character of the first word in a sentence. Could a script change the first character after a single period to uppercase? The single period is an important point - often "..." is used with descriptions in this text to bridge copy.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

uppercase to lowercase

Greetings & Happy New Years To All! A client of mine FTP'ed their files up to the server and it all ended up being in UPPERCASE when it all should be in lowercase. Is there a builtin command or a script anyone knows of that will automagically convert all files to lowercase? Please advise asap... (4 Replies)
Discussion started by: webex
4 Replies

2. AIX

Lowercase to Uppercase

Inside a script I have 2 variables COMP=cy and PT=t. further down the same script I require at the same line to call those 2 variables the first time uppercase and after lowercase ${COMP}${PT}ACE,${COMP}${PT}ace. Can somebody help me Thanks in advance George Govotsis (7 Replies)
Discussion started by: ggovotsis
7 Replies

3. UNIX for Dummies Questions & Answers

uppercase to lowercase

i have no variable and no file i just want to convert AJIT to ajit with some command in UNIX can anybody help (4 Replies)
Discussion started by: ajit.yadav83
4 Replies

4. Shell Programming and Scripting

sed help to convert from lowercase to uppercase and vice versa!

Hello, can sed be used to convert all letters of a file from uppercase to lowercase and vice versa?i know tr command can be used but with sed is it possible? i came up with this :- sed 'y///' file1 actually the above command is also not working! Please help me. Thanks in advance :) (6 Replies)
Discussion started by: salman4u
6 Replies

5. UNIX Desktop Questions & Answers

Unix: lowercase to uppercase

I just started to learn unix... and i needed to make a basic script. i need to 1. read a file (.txt) 2. count the words of EVERY sentece 3. sentences with odd number of words need to be converted into lowercase sentences with even number of words need to be converted into uppercase ... (6 Replies)
Discussion started by: chilli1988
6 Replies

6. UNIX for Dummies Questions & Answers

UPPERCASE to lowercase

Hi All, i have a file and i want to convert all uppercase letters to lowercase letters which are in my file. how can i do this. Thanx (3 Replies)
Discussion started by: temhem
3 Replies

7. Shell Programming and Scripting

Convert to upper case first letter of each word in column 2

Hi guys, I have a file separated by ",". I´m trying to change to upper case the first letter of each word in column 2 to establish a standard format on this column. I hope somebody could help me to complete the SED or AWK script below. The file looks like this: (Some lines in column 2... (16 Replies)
Discussion started by: cgkmal
16 Replies

8. Shell Programming and Scripting

making the first character of word using uppercase using awk and sed

I want to make the first character of some words to be uppercase. I have a file like the one below. uid,givenname,sn,cn,mail,telephonenumber mattj,matt,johnson,matt johnson,mattj@gmail.com markv,mark,vennet,matt s vennet,markv@gmail.com mikea,mike,austi,mike austin,mike@gmail.com I want... (3 Replies)
Discussion started by: matt12
3 Replies

9. Shell Programming and Scripting

Uppercase to lowercase

Hello, I have a list of files in a directory whose names are all in uppercasse, including the file format for eg *.MP3 . I would like to convert these to the normal way we write it ie ABC.MP3 to be converted to Abc.mp3 . I know that this can be done manually by using a lot of "mv" or rename... (6 Replies)
Discussion started by: ajayram
6 Replies

10. Shell Programming and Scripting

Change first letter of a word from lower case to upper case

Hi all, I am trying to find a way to change first letter in a word from lower case to upper case. It should be done for each first word in text or in paragraph, and also for each word after punctuation like . ; : ! ?I found the following command sed -i 's/\s*./\U&\E/g' $@ filenamebut... (7 Replies)
Discussion started by: georgi58
7 Replies
Date::Manip::Lang::russian(3)				User Contributed Perl Documentation			     Date::Manip::Lang::russian(3)

NAME
Date::Manip::Lang::russian - Russian language support. SYNOPSIS
This module contains a list of words and expressions supporting the language. It is not intended to be used directly (other Date::Manip modules will load it as needed). LANGUAGE EXPRESSIONS
The following is a list of all language words and expressions used to write times and/or dates. All strings are case insensitive. Month names and abbreviations When writing out the name of the month, several different variations may exist including full names and abbreviations. The following month names may be used: XXXXXX XXXXXX XXXXXXX XXXXXXX XXXXX XXXX XXXXXX XXXXXX XXX XXX XXXX XXXX XXXX XXXX XXXXXXX XXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXX XXXXXX XXXXXX XXXXXXX XXXXXXX The following abbreviations may be used: XXX XXX. XXX XXX XXXX. XXX XXXXX XXXX XXX XXX. XXX XXX XXX XXXX XXXX XXX XXXX XXXX XXX XXX. XXX XXX XXXX. XXX XXX. XXXX XXX XXXX. XXX XXX. Day names and abbreviations When writing out the name of the day, several different variations may exist including full names and abbreviations. The following day names may be used: XXXXXXXXXXX XXXXXXX XXXXX XXXXXXX XXXXXXX XXXXXXX XXXXXXXXXXX The following abbreviations may be used: XXX XX XXX XXX XX XXX XXX XX XXe XXX XX XXX XXX XX XXX XXX XX XXX XXX XX XXXX The following short (1-2 characters) abbreviations may be used: XX XX XX XX XX XX XX Delta field names These are the names (and abbreviations) for the fields in a delta. There are 7 fields: years, months, weeks, days, hours, minutes, seconds. The names and abbreviations for these fields are: X XX XXX XXX XXX XXXX XXX XXXXX XXXXXXX XXXXXX XXXXXX XXXXXX XXXXXX X XXXX XXXX XXX X X. XX XXX XXX XXXXX XXXX XX XXX XXXXXX XXXXX X XXX XXXXXXX XXXXXX Morning/afternoon times This is a list of expressions use to designate morning or afternoon time when a time is entered as a 12-hour time rather than a 24-hour time. For example, in English, the time "17:00" could be specified as "5:00 PM". Morning and afternoon time may be designated by the following sets of words: XX XX X.X. XXXX XXXX XX XXXXXXX XX XX X.X. XXX XXXXXX XXXXX XXXXXXX XX XXXXXXX Each or every There are a list of words that specify every occurence of something. These are used in the following phrases: EACH Monday EVERY Monday EVERY month The following words may be used: XXXXXX Next/Previous/Last occurence There are a list of words that may be used to specify the next, previous, or last occurence of something. These words could be used in the following phrases: NEXT week LAST tuesday PREVIOUS tuesday LAST day of the month The following words may be used: Next occurence: XXXXXXXXX Previous occurence: XXXXXXXXXX Last occurence: XXXXXXXXX Delta words for going forward/backward in time When parsing deltas, there are words that may be used to specify the the delta will refer to a time in the future or to a time in the past (relative to some date). In English, for example, you might say: IN 5 days 5 days AGO The following words may be used to specify deltas that refer to dates in the past or future respectively: XXXXX XX XXXXXX XX XXXXX Business mode This contains two lists of words which can be used to specify a standard (i.e. non-business) delta or a business delta. Previously, it was used to tell whether the delta was approximate or exact, but now this list is not used except to force the delta to be standard. The following words may be used: XXXXX XXXXXXXX The following words may be used to specify a business delta: XXXXXXX Numbers Numbers may be spelled out in a variety of ways. The following sets correspond to the numbers from 1 to 53: 1 XXXXXX XXXXXXX XXXXXX XXXX 2 XXXXXX XXXXXXX XXXXXX XXX 3 XXXXXX XXXXXXXX XXXXXX XXX 4 XXXXXXXXX XXXXXXXXXX XXXXXXXXX XXXXXX 5 XXXXX XXXXXX XXXXX XXXX 6 XXXXXX XXXXXXX XXXXXX XXXXX 7 XXXXXXX XXXXXXXX XXXXXXX XXXX 8 XXXXXXX XXXXXXXX XXXXXXX XXXXXX 9 XXXXXXX XXXXXXXX XXXXXXX XXXXXX 10 XXXXXXX XXXXXXXX XXXXXXX XXXXXX 11 XXXXXXXXXXXX XXXXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX 12 XXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXX 13 XXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXX 14 XXXXXXXXXXXXX XXXXXXXXXXXXXX XXXXXXXXXXXXX XXXXXXXXXXXX 15 XXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX XXXXXXXXXX 16 XXXXXXXXXXXX XXXXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX 17 XXXXXXXXXXXX XXXXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXX 18 XXXXXXXXXXXXXX XXXXXXXXXXXXXXX XXXXXXXXXXXXXX XXXXXXXXXXXX 19 XXXXXXXXXXXXX XXXXXXXXXXXXXX XXXXXXXXXXXXX XXXXXXXXXXXX 20 XXXXXXXXX XXXXXXXXXX XXXXXXXXX XXXXXXXX 21 XXXXXXXX XXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXX 22 XXXXXXXX XXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXXX XXXXXXXX XXX 23 XXXXXXXX XXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXX 24 XXXXXXXX XXXXXXXXX XXXXXXXX XXXXXXXXXX XXXXXXXX XXXXXXXXX XXXXXXXX XXXXXX 25 XXXXXXXX XXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXX XXXXXXXX XXXX 26 XXXXXXXX XXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXX 27 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXX 28 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX 29 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX 30 XXXXXXXXX XXXXXXXXXX XXXXXXXXX XXXXXXXX 31 XXXXXXXX XXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXX 32 XXXXXXXX XXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXXX XXXXXXXX XXX 33 XXXXXXXX XXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXX 34 XXXXXXXX XXXXXXXXX XXXXXXXX XXXXXXXXXX XXXXXXXX XXXXXXXXX XXXXXXXX XXXXXX 35 XXXXXXXX XXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXX XXXXXXXX XXXX 36 XXXXXXXX XXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX XXXXXXXX XXXXX 37 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXX 38 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX 39 XXXXXXXX XXXXXXX XXXXXXXX XXXXXXXX XXXXXXXX XXXXXXX XXXXXXXX XXXXXX 40 XXXXXXXXX XXXXX 41 XXXXX XXXXXX XXXXX XXXXXXX XXXXX XXXXXX XXXXX XXXX 42 XXXXX XXXXXX XXXXX XXXXXX XXXXX XXXXXX XXXXX XXX 43 XXXXX XXXXXX XXXXX XXXXXXXX XXXXX XXXXXX XXXXX XXX 44 XXXXX XXXXXXXXX XXXXX XXXXXXXXXX XXXXX XXXXXXXXX XXXXX XXXXXX 45 XXXXX XXXXX XXXXX XXXXXX XXXXX XXXXX XXXXX XXXX 46 XXXXX XXXXXX XXXXX XXXXXXX XXXXX XXXXXX XXXXX XXXXX 47 XXXXX XXXXXXX XXXXX XXXXXXXX XXXXX XXXXXXX XXXXX XXXX 48 XXXXX XXXXXXX XXXXX XXXXXXXX XXXXX XXXXXXX XXXXX XXXXXX 49 XXXXX XXXXXXX XXXXX XXXXXXXX XXXXX XXXXXXX XXXXX XXXXXX 50 XXXXXXXXXXX XXXXXXXXXXXX XXXXXXXXXXX XXXXXXXXX 51 XXXXXXXXX XXXXXX XXXXXXXXX XXXXXXX XXXXXXXXX XXXXXX XXXXXXXXX XXXX 52 XXXXXXXXX XXXXXX XXXXXXXXX XXXXXX XXXXXXXXX XXXXXX XXXXXXXXX XXX 53 XXXXXXXXX XXXXXX XXXXXXXXX XXXXXXXX XXXXXXXXX XXXXXX XXXXXXXXX XXX Ignored words In writing out dates in common forms, there are a number of words that are typically not important. There is frequently a word that appears in a phrase to designate that a time is going to be specified next. In English, you would use the word AT in the example: December 3 at 12:00 The following words may be used: X Another word is used to designate one member of a set. In English, you would use the words IN or OF: 1st day OF December 1st day IN December The following words may be used: Not defined in this language Another word is use to specify that something is on a certain date. In English, you would use ON: ON July 5th The following words may be used: X Words that set the date, time, or both There are some words that can be used to specify a date, a time, or both relative to now. Words that set the date are similar to the English words 'yesterday' or 'tomorrow'. These are specified as a delta which is added to the current time to get a date. The time is NOT set however, so the delta is only partially used (it should only include year, month, week, and day fields). The following words may be used: XXXXX -0:0:0:1:0:0:0 XXXXXX +0:0:0:1:0:0:0 XXXXXXXXX -0:0:0:2:0:0:0 XXXXXXXXXXX +0:0:0:2:0:0:0 XXXXXXX 0:0:0:0:0:0:0 Words that set only the time of day are similar to the English words 'noon' or 'midnight'. The following words may be used: XXXXXXX 12:00:00 XXXXXXX 00:00:00 Words that set the entire time and date (relative to the current time and date) are also available. In English, the word 'now' is one of these. The following words may be used: XXXXXX 0:0:0:0:0:0:0 Hour/Minute/Second separators When specifying the time of day, the most common separator is a colon (:) which can be used for both separators. Some languages use different pairs. For example, French allows you to specify the time as 13h30:20, so it would use the following pairs: : : [h] [:] The first column is the hour-minute separator and the second column is the minute-second separator. Both are perl regular expressions. A pair of colons is ALWAY allowed for all languages. If a language allows additional pairs, they are listed here: [X] [X] KNOWN BUGS
None known. BUGS AND QUESTIONS
Please refer to the Date::Manip::Problems documentation for information on submitting bug reports or questions to the author. SEE ALSO
Date::Manip - main module documentation LICENSE
This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself. AUTHOR
Sullivan Beck (sbeck@cpan.org) perl v5.16.3 2014-06-09 Date::Manip::Lang::russian(3)
All times are GMT -4. The time now is 06:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy