Sponsored Content
Special Forums Windows & DOS: Issues & Discussions Simple 'date' to 001 scheme script Post 302958193 by pasc on Tuesday 20th of October 2015 07:24:07 AM
Old 10-20-2015
Thanks!

Busybox seems to be rather useful Smilie.
 

10 More Discussions You Might Find Interesting

1. Tips and Tutorials

Simple date and time calulation in BASH

The GNU date command in full of goodies but not when it comes to calculate a date or time difference. Here is what I came up with after looking to more than one solution. Code should be self explaining. #!/bin/bash date2stamp () { date --utc --date "$1" +%s } stamp2date (){ ... (0 Replies)
Discussion started by: ripat
0 Replies

2. HP-UX

a simple way of converting a date in seconds to normal date

Hi all! I'm working on a HPUX system, and I was wondering if there is a simple way to convert a date from seconds (since 1970) to a normal date. Thanks (2 Replies)
Discussion started by: travian
2 Replies

3. Shell Programming and Scripting

simple date problem

i have a script that grep for today date a=`date +"%F"`--------greps current/today date wat if suppose i want to grep a date for yesterday... how to do that using the above format: i,e 2008-01-20 (4 Replies)
Discussion started by: ali560045
4 Replies

4. Shell Programming and Scripting

Simple date formatting?

Hi guys, I have some embedded perl within my shell script to get me the modification time/date of a file which returns me the following string: Fri May 1 09:52:58 2009 I have managed to get the bits i need such as 1-May-2009, but what i would prefer is 010509 instead... Here is my... (4 Replies)
Discussion started by: muay_tb
4 Replies

5. Shell Programming and Scripting

Simple date issue

Hi all, i have used the search already before someone shouts at me and i have seen the 'datecalc' program but this is not working correctly for me in the shell and environment i am using. I am using solaris 10 and bourne shell. I have two dates '07-04-2009' and '05-05-2009'. I just need to... (2 Replies)
Discussion started by: muay_tb
2 Replies

6. Shell Programming and Scripting

How can get the value 001 using shell script

Hi Gurus, Please help in this shell script. x=000 y=`expr $x + 1` echo $y which gives me the value as 1 How can i get the value as 001 in this shell script. As i am new to scripting stuck up here. Requesting here help here (2 Replies)
Discussion started by: nmadhuhb
2 Replies

7. Shell Programming and Scripting

Help making simple perl or bash script to create a simple matrix

Hello all! This is my first post and I'm very new to programming. I would like help creating a simple perl or bash script that I will be using in my work as a junior bioinformatician. Essentially, I would like to take a tab-delimted or .csv text with 3 columns and write them to a "3D" matrix: ... (16 Replies)
Discussion started by: torchij
16 Replies

8. Shell Programming and Scripting

Simple date and time calulation in BASH

There is a closed Thread: <url>Here will be the url to the original post once I have 5 posts in this forum...</url> But a small bug had found his way into this very cool and simple code. #!/bin/bash date2stamp () { date --utc --date "$1" +%s } stamp2date (){ date --utc --date... (2 Replies)
Discussion started by: frood
2 Replies

9. Shell Programming and Scripting

Simple date issue

Hi , Here is the smaller version of the problem. Working individually as command ************************>echo $SHELL /bin/bash ************************>TO_DAY=`date` ************************>echo $TO_DAY Tue Jul 16 02:28:31 EDT 2013 ************************> Not working when... (5 Replies)
Discussion started by: Anupam_Halder
5 Replies

10. Shell Programming and Scripting

How to do simple date (time) calculation in shell script?

Hi, I'm looking for a way to do a simple math calc during a shell script as a means of logging how long a particular task takes. For example... STARTTIME=whenever this script starts ./path/to/command.sh >>logfile.log TOTALTIME=<time at this stage of the script after above command... (7 Replies)
Discussion started by: nbsparks
7 Replies
LOADKEYS(1)						      General Commands Manual						       LOADKEYS(1)

NAME
loadkeys - load keyboard translation tables SYNOPSIS
loadkeys [ -a --ascii ] [ [ -b --bkeymap ] [ -c --clearcompose ] [ -C '<FILE>' | --console=<FILE> ] [ -d --default ] [ -h --help ] [ -m --mktable ] [ -p --parse ] [ -q --quiet ] [ -s --clearstrings ] [ -u --unicode ] [ -v --verbose ] [ -V --version ] [ filename... ] DESCRIPTION
The program loadkeys reads the file or files specified by filename.... Its main purpose is to load the kernel keymap for the console. You can specify console device by the -C (or --console ) option. RESET TO DEFAULT
If the -d (or --default ) option is given, loadkeys loads a default keymap, probably the file defkeymap.map either in /usr/share/keymaps or in /usr/src/linux/drivers/char. (Probably the former was user-defined, while the latter is a qwerty keyboard map for PCs - maybe not what was desired.) Sometimes, with a strange keymap loaded (with the minus on some obscure unknown modifier combination) it is easier to type `loadkeys defkeymap'. LOAD KERNEL KEYMAP
The main function of loadkeys is to load or modify the keyboard driver's translation tables. When specifying the file names, standard input can be denoted by dash (-). If no file is specified, the data is read from the standard input. For many countries and keyboard types appropriate keymaps are available already, and a command like `loadkeys uk' might do what you want. On the other hand, it is easy to construct one's own keymap. The user has to tell what symbols belong to each key. She can find the keycode for a key by use of showkey(1), while the keymap format is given in keymaps(5) and can also be seen from the output of dumpkeys(1). LOAD KERNEL ACCENT TABLE
If the input file does not contain any compose key definitions, the kernel accent table is left unchanged, unless the -c (or --clearcompose ) option is given, in which case the kernel accent table is emptied. If the input file does contain compose key definitions, then all old definitions are removed, and replaced by the specified new entries. The kernel accent table is a sequence of (by default 68) entries describing how dead diacritical signs and compose keys behave. For example, a line compose ',' 'c' to ccedilla means that <ComposeKey><,><c> must be combined to <ccedilla>. The current content of this table can be see using `dumpkeys --com- pose-only'. LOAD KERNEL STRING TABLE
The option -s (or --clearstrings ) clears the kernel string table. If this option is not given, loadkeys will only add or replace strings, not remove them. (Thus, the option -s is required to reach a well-defined state.) The kernel string table is a sequence of strings with names like F31. One can make function key F5 (on an ordinary PC keyboard) produce the text `Hello!', and Shift+F5 `Goodbye!' using lines keycode 63 = F70 F71 string F70 = "Hello!" string F71 = "Goodbye!" in the keymap. The default bindings for the function keys are certain escape sequences mostly inspired by the VT100 terminal. CREATE KERNEL SOURCE TABLE
If the -m (or --mktable ) option is given loadkeys prints to the standard output a file that may be used as /usr/src/linux/drivers/char- /defkeymap.c, specifying the default key bindings for a kernel (and does not modify the current keymap). CREATE BINARY KEYMAP
If the -b (or --bkeymap ) option is given loadkeys prints to the standard output a file that may be used as a binary keymap as expected by Busybox loadkmap command (and does not modify the current keymap). UNICODE MODE
loadkeys automatically detects whether the console is in Unicode or ASCII (XLATE) mode. When a keymap is loaded, literal keysyms (such as section) are resolved accordingly; numerical keysyms are converted to fit the current console mode, regardless of the way they are speci- fied (decimal, octal, hexadecimal or Unicode). The -u (or --unicode) switch forces loadkeys to convert all keymaps to Unicode. If the keyboard is in a non-Unicode mode, such as XLATE, loadkeys will change it to Unicode for the time of its execution. A warning message will be printed in this case. It is recommended to run kbd_mode(1) before loadkeys instead of using the -u option. OTHER OPTIONS
-a --ascii Force conversion to ASCII. -h --help loadkeys prints its version number and a short usage message to the programs standard error output and exits. -p --parse loadkeys searchs and parses keymap without action. -q --quiet loadkeys suppresses all normal output. -V --version loadkeys prints version number and exits. WARNING
Note that anyone having read access to /dev/console can run loadkeys and thus change the keyboard layout, possibly making it unusable. Note that the keyboard translation table is common for all the virtual consoles, so any changes to the keyboard bindings affect all the virtual consoles simultaneously. Note that because the changes affect all the virtual consoles, they also outlive your session. This means that even at the login prompt the key bindings may not be what the user expects. FILES
/usr/share/keymaps default directory for keymaps /usr/src/linux/drivers/char/defkeymap.map default kernel keymap SEE ALSO
dumpkeys(1), keymaps(5) 6 Feb 1994 LOADKEYS(1)
All times are GMT -4. The time now is 07:25 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy