Does anyone have the exec for date? « My Humax Forum

My Humax Forum » Freesat HD » FOXSAT HDR

Does anyone have the exec for date?

(3 posts)
  1. REPASSAC

    REPASSAC

    special member
    Joined: Mar '11
    Posts: 3,708

    offline

    Being a bit lazy - I don't really want to learn how to recompile busybox source. I am playing with a script and need to know the date.

    Fri 24 Jun 2011 18:43:55 #1 |
  2. User has not uploaded an avatar

    raydon

    special member
    Joined: Feb '11
    Posts: 159

    offline

    REPASSAC - 3 hours ago  » 
    Being a bit lazy - I don't really want to learn how to recompile busybox source. I am playing with a script and need to know the date.

    Hi David,

    1. Download the precompiled mips binary from http://www.busybox.net/downloads/binaries/1.18.4/busybox-mips
    2. Using FTP, copy it to the /opt/bin directory on the HDR and rename it to busybox.
    3. Create a symlink for the date command by opening a telnet session on the HDR and entering:
    ln -s /opt/bin/busybox /opt/bin/date
    Now when you type
    date --help
    you should see:

    BusyBox v1.18.4 (2011-04-04 19:31:40 CDT) multi-call binary.

    Usage: date [OPTIONS] [+FMT] [TIME]

    Display time (using +FMT), or set time

    Options:
    [-s,--set] TIME Set time to TIME
    -u,--utc Work in UTC (don't convert to local time)
    -R,--rfc-2822 Output RFC-2822 compliant date string
    -I[SPEC] Output ISO-8601 compliant date string
    SPEC='date' (default) for date only,
    'hours', 'minutes', or 'seconds' for date and
    time to the indicated precision
    -r,--reference FILE Display last modification time of FILE
    -d,--date TIME Display TIME, not 'now'
    -D FMT Use FMT for -d TIME conversion

    Recognized TIME formats:
    hh:mm[:ss]
    [YYYY.]MM.DD-hh:mm[:ss]
    YYYY-MM-DD hh:mm[:ss]
    [[[[[YY]YY]MM]DD]hh]mm[.ss]

    Unfortunately, the date still needs to be initialised by 'settop' before the date function will return a valid value.

    You may also want to try:

    compare:
    ln -s /opt/bin/busybox /opt/bin/cmp

    and
    difference:
    ln -s /opt/bin/busybox /opt/bin/diff

    Any other command you may need, you can create a symlink for by using the same method outlined above.
    Just enter
    busybox
    for a full list of the commands you already have
    and
    /opt/bin/busybox
    for the commands that are available.

    regards
    raydon

    Fri 24 Jun 2011 23:08:39 #2 |
  3. REPASSAC

    REPASSAC

    special member
    Joined: Mar '11
    Posts: 3,708

    offline

    Many thanks raydon.

    Sat 25 Jun 2011 9:35:11 #3 |

RSS feed for this topic

Reply

You must log in to post.