[prev in list] [next in list] [prev in thread] [next in thread] 

List:       illumos-developer
Subject:    Re: [developer] illumos Gerrit Documentation
From:       "Joshua M. Clulow" <josh () sysmgr ! org>
Date:       2020-07-24 15:26:29
Message-ID: CAEwA5nJGPQ6U5y6YDA57_2ByPf30qvo66UvNT6jR8YyJB7WroA () mail ! gmail ! com
[Download RAW message or body]

On Fri, 24 Jul 2020 at 08:22, Andy Fiddaman <andy@omniosce.org> wrote:
> random=$( (whoami ; hostname ; date; git show ; echo $RANDOM) | \
>     git hash-object --stdin)

You can also do something like:

    $ echo "Change-Id: I$(head -c 1024 /dev/urandom | digest -a sha1)"
    Change-Id: I447197e8f0a2dfe5c487256995a065ed1c1ecd3a

It just needs to be random and the large space of possible random
values makes it extremely unlikely you'll collide.


Cheers.

-- 
Joshua M. Clulow
http://blog.sysmgr.org

------------------------------------------
illumos: illumos-developer
Permalink: https://illumos.topicbox.com/groups/developer/T6328a9bfd58f34d7-M5f14267077c3b17fa53fd880
Delivery options: https://illumos.topicbox.com/groups/developer/subscription
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic