Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

netsds::util::datetime(3pm) [debian man page]

NetSDS::Util::DateTime(3pm)				User Contributed Perl Documentation			       NetSDS::Util::DateTime(3pm)

NAME
NetSDS::Util::DateTime - common date/time processing routines SYNOPSIS
use NetSDS::Util::DateTime; print "Current date: " . date_now(); DESCRIPTION
This package provides set of routines for date and time processing. EXPORTED FUNCTIONS
date_now_array([TIME]) Returns array of date items for given date. If source date is not set current date used. date_now([TIME]) Return [given] date as string. 2001-12-23 14:39:53 date_now_iso8601([TIME]) Return date as ISO 8601 string. 20011223T14:39:53Z <http://en.wikipedia.org/wiki/ISO_8601> http://www.w3.org/TR/NOTE-datetime <http://www.w3.org/TR/NOTE-datetime> date_strip(DATE) Trim miliseconds from date. date_date(DATE) Trim time part from date. date_time(DATE) Trim date part from date. time_from_string($string) Return parsed date/time structure. date_from_string($string) Return date from string representation. date_inc([INCREMENT, [TIME]]) Return date incremented with given number of seconds. date_inc_string([INCREMENT, [TIME]]) Return string representation of date incremented with given number of seconds. EXAMPLES
None yet BUGS
Unknown yet SEE ALSO
Date::Parse, Date::Format TODO
Import stuff from Wono project AUTHOR
Valentyn Solomko <val@pere.org.ua> Michael Bochkaryov <misha@rattler.kiev.ua> perl v5.12.4 2011-08-27 NetSDS::Util::DateTime(3pm)

Check Out this Related Man Page

NetSDS::Util::Convert(3pm)				User Contributed Perl Documentation				NetSDS::Util::Convert(3pm)

NAME
NetSDS::Util::Convert - data formats conversion functions SYNOPSIS
use NetSDS::Util::Convert qw(...); DESCRIPTION
"NetSDS::Util::Convert" module contains miscelaneous functions. o CLI parameters processing o types validation o HEX, Base64, URI, BCD encondig o UUID processing EXPORTED FUNCTIONS
conv_conv_str_bcd($str) - convert string to little-endian BCD This function converts string to little-endian BCD encoding filled with F16 value. conv_chr_hex($char) - encode char to hexadecimal string $hex = conv_chr_hex('a'); # return 61 conv_hex_chr($hex) - convert hexadecimal string to character $chr = conv_hex_chr('4A'); # return 'J' conv_str_hex($str) - convert byte string to hexadecimal $str = 'Want hex dump!'; $hex = conv_hex_str($str); print "Hex string: " . $hex; conv_hex_str($string) - convert hex to byte string $hex = '7A686F7061'; $string = conv_hex_str($hex); print "String from hex: " . $string; conv_str_base64($str) - convert string to Base64 my $b64 = str_base64("Hallo, people!"); conv_base64_str($b64) - convert Base64 to string my $str = base64_str($base64_string); conv_str_uri($str) - convert string to URI encoded Example: my $uri = str_uri("http://www.google.com/?q=what"); conv_uri_str($uri) - decode URI encoded string Example: my $str = uri_str($uri_string); EXAMPLES
None BUGS
None TODO
1. Add other encodings support SEE ALSO
Pod::Usage, Data::UUID AUTHORS
Valentyn Solomko <pere@pere.org.ua> Michael Bochkaryov <misha@rattler.kiev.ua> perl v5.12.4 2011-08-27 NetSDS::Util::Convert(3pm)
Man Page

15 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Bash comparing date

Cound anyone help me on how to compare date in Unix using if function on bash file? current=date if ###syntax is wrong, could anyone correct it for me then rm -rf /usr/local/src fi Thank You... (17 Replies)
Discussion started by: Stanford Co
17 Replies

2. Shell Programming and Scripting

Extracting Date from string

Hi Gurus I want to extract a date and version code which shall come in filename consisting of underscores. The filename can contain any / one underscores but the version number will come after date and will be separted by underscore String formats ============= ABC_20090815_2.csv... (13 Replies)
Discussion started by: r_t_1601
13 Replies

3. Shell Programming and Scripting

Getting yesterday DATE

Hi It is possible pass to one program a parameter YESTERDAY DATE , i mean the current date less one day (sysdate -1) ? (21 Replies)
Discussion started by: osymad
21 Replies

4. Shell Programming and Scripting

Last sunday of current date

Hi Please help me with this problem i need to find the date of last week sunday from the current given date (12 Replies)
Discussion started by: aishsimplesweet
12 Replies

5. Shell Programming and Scripting

killing a process by date

Folks , Trying to create a script / command that kills an application process , but on the ones that are from the current date backwards. So far I have everything working minus the "date" part. Can you help me ? current command : kill -9 `ps -aef | grep app_name | grep -v grep | awk... (13 Replies)
Discussion started by: iMark
13 Replies

6. Shell Programming and Scripting

Date not displaying correctly

Hi Experts, I tried to stay away from posting stuff here and asking for help. I want to print date valeu for a given variable and that is not working. #!/bin/bash START=`echo $1 | tr -d _`; FV=`echo $2` for (( c = 0 ; c < $FV ; c++ )) do # echo -n "`date --date="$START +$c day"... (12 Replies)
Discussion started by: PG3
12 Replies

7. Shell Programming and Scripting

Shell script (KSH) to list ONLY the ID of male employees whose last loging time was during the last

Can someone help me on my issue please :) I have a table like this format: # cat myfile.txt Employee Gender NAME Last Login ID Time ------------------------------------------------- 210125 M ABC ... (15 Replies)
Discussion started by: Sara_84
15 Replies

8. Shell Programming and Scripting

Perl script

Hi All, I have a question here in perl script Suppose I have a date 12/22/2011(mm/dd/yyyy) what i have to do is to find the start date of the week in which that date lies and end date of that week. In this scenario the start date will be 12/19/2011 and the end date will be 12/25/2011:b: (21 Replies)
Discussion started by: parthmittal2007
21 Replies

9. Shell Programming and Scripting

Date command

Just writing a script as part of a backup procedure to use a data file 7 days previous if there has not been one sent over. Got stuck on trying to get the date command to insert the date from 7 days ago i.e. todays date is 12/09/10 7 days ago would be 12/09/03 I would want the date command... (30 Replies)
Discussion started by: 02JayJay02
30 Replies

10. Shell Programming and Scripting

Loop questions

hi all, i'm trying to create a script inorder to put load test on hard drives. first i create 30GB file dd if=/dev/zero of=50gb.img bs=5gb count=10 then i'd like to create 100 loops continuous until it fills up. once its done delete file. this is where i'm stuck for for loops. can... (18 Replies)
Discussion started by: kernel11
18 Replies

11. Shell Programming and Scripting

What does this mean?

Hello all, I am a newbie in shell scripting. I want to know what does the below text means? 6.355u 1.679s 0:12.68 63.2% 0+0k 0+0io 0pf+0w I am getting this line (on terminal) after every successful execution of my script. Thanks in advance . . :) -MD (15 Replies)
Discussion started by: manands07
15 Replies

12. HP-UX

Dmesg with date possible?

Hi there, I miss date information when executing # dmesg Is it possible to add this a date information to my results of # dmesg ? Best wishes (12 Replies)
Discussion started by: System
12 Replies

13. Shell Programming and Scripting

Find big file include current date

Hi, I want to put script. The script is to show file that larger than 100MB include current date (eg: today date). After find the date, it will compress list file and split the tar.gz file. Any idea how to do that? This bash script will run auto everyday. It's will transfer will to other... (12 Replies)
Discussion started by: mzainal
12 Replies

14. UNIX for Beginners Questions & Answers

Getting error while using date as a variable in expect

Hi getting error when i am saving date command output in a variable and then using the same variable in expect #!/usr/bin/expect set DATE spawn sftp AUT#XX.XX.XX.XX spawn echo $DATE expect "password:" send "AT123\n" expect "sftp>" send "cd /home/ \r" expect "sftp>" send... (12 Replies)
Discussion started by: scriptor
12 Replies

15. HP-UX

awk command in hp UNIX subtract 30 days automatically from current date without date illegal option

current date command runs well awk -v t="$(date +%Y-%m-%d)" -F "'" '$1 < t' myname.dat subtract 30 days fails awk -v t="$(date --date="-30days" +%Y-%m-%d)" -F "'" '$1 < t' myname.dat awk command in hp unix subtract 30 days automatically from current date without date illegal option error... (20 Replies)
Discussion started by: kmarcus
20 Replies