Re: [SLE] Help me please

From: qrn_Hansen?= (orn.hansen_at_swipnet.se)
Date: 04/01/04

  • Next message: Hollweg, Daniel: "[SLE] cron for normal users"
    To: suse-linux-e@suse.com
    Date: Thu, 1 Apr 2004 11:21:43 +0200
    
    

    torsdag 01 april 2004 10:17 skrev handy:
    > Hi I am a novice in Linux.
    > I want to do something in my sles with create a script for my database...my
    > question is :
    >
    > 1. How to create a filename with date month year :
    > For example : my filename -> backup30012004
    > 2. If I want compress with gzip, can I create the filename with date month
    > year directly . For example : gzip -9 backup30012004
    > If it is can be... how to make it
    >

    it's simple,

    my_filename=backup`date +"%d%m%Y"`

    in a shell script, and $filename will hold the name you selected above.

    -- 
    Check the headers for your unsubscription address
    For additional commands send e-mail to suse-linux-e-help@suse.com
    Also check the archives at http://lists.suse.com
    Please read the FAQs: suse-linux-e-faq@suse.com
    

  • Next message: Hollweg, Daniel: "[SLE] cron for normal users"

    Relevant Pages

    • Re: "system" with [ ] in filename
      ... In a perl script I do this: ... Or should I look for the problem in the way Windows handles the in the filename? ... Come over and you make it work on Linux. ... I do not see your code where you transform/read/determine the filename to be written, but a simple routine to make it entirely unique - without the "" would not be out of the question here and would solve the overall problem - giving you time for submitting a bug report to the *magick folks. ...
      (comp.lang.perl.misc)
    • find, foreach and embedded spaces
      ... I'm trying to findf and process a bunch of files in a shell script (either ... results in foreach seeing each piece of the filename as a separate token. ... I get the same results using "for f in `...as above...`" in bash. ...
      (comp.unix.shell)
    • Re: Opinions on new PDA please
      ... After replacing longgone@xxxxxxxxxxxx with a small shell script on ... advocate people switching blindly from Windows to Linux, BSD or MacOS. ... Martin is quite correct when he says that if Linux had a larger install ... DesktopBSD are coming along nicely. ...
      (uk.comp.sys.palmtops)
    • Re: Free FAT12/FAT16/FAT32 filesystem (C)
      ... There is an oddity about the vfat driver in Linux, ... prettify directory output by silently lowercasing 8.3 names when you ... IIRC if a filename you create COULD be represented ... it will always be preferred display. ...
      (comp.arch.embedded)
    • Regexp for parsing windows filepath on Unix
      ... I'm able to capture the file and move it over intact to my Linux box with no problem. ... I've discovered that when a user uploads the file with IE, the entire path to the file is sent (as opposed to FireFox which only returns the filename). ...
      (comp.lang.perl.misc)