Menu

autoproductname with bash variables

Help
Suncatcher
2018-08-19
2018-09-06
  • Suncatcher

    Suncatcher - 2018-08-19

    We have autoproductname key for ocs-sr command which generates image name automatically based on wmi PC data. How can one append date to this autogenerated name?

    I tried

    autoproductname-$(date '+%Y-%m-%d-%H%M')
    

    and it didn't work. It created autoproductname-2018-06-10-02 folder.

    While Bash date function appended with literals works brilliantly. Any hints?

     

    Last edit: Suncatcher 2018-08-19
  • Steven Shiau

    Steven Shiau - 2018-09-06

    I do not understand. It already created the name "autoproductname-2018-06-10-02", so it's not what you want?
    For more about bash, you can refer to:
    https://www.tldp.org/LDP/abs/html/

    Steven

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.