From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 18334 invoked from network); 21 Nov 2022 01:07:32 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 21 Nov 2022 01:07:32 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1668992852; b=H/jn79oM6arPu/ocTdyNVcR4Fhsq4lF79mDyTE0lkGC6SCi7SaMoEXBaQ7i6WUDQSF0/yK8A/u GynorE4W7IaEL3w0hIfttlQXBLoJyz32aGtA0EZ4Pv0HbkGkNWNccKwaiPJiIi49M2gDA6wXTS hOHKwh8ny3Ptai3jheNsETCu7jSKpd0lFyYhRhsMr13YL10/0+ducuKdLr6DZ/nCED3kXsGrg6 8cZR3KQc5d191/yTY4jClHIJsQiJyl445Bw2vwZBRdGhMopTsITE4ap/QwPG2FgtsrQosoGpYD sm7XId0IY/ckH1F6WXSYTrGeVVYjyYcgStPWM5lWdbVJ/g==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-oi1-f173.google.com) smtp.remote-ip=209.85.167.173; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1668992852; bh=3D+TEmNMCcRtQvOMX7f5mNSUB35MMO8D1Xtb6EBN7lI=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:In-Reply-To:Content-Transfer-Encoding:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:DKIM-Signature: DKIM-Signature; b=oTDg4KpdAoveBki+/k9s+fx1NefIWjecB/m2beJXCK5fOy2pe6wJHqouhMNA+YpNvBG329HCCA b1++EOxMVytWTOhbJ1bHq7xdB2YZfhU9EHCEm8Q0heKikJ/0xkOJ2ooPPurwPRviT3cUzSgf47 4RLN7H0oTQs4xpTUgA2fRq6H7SZnOQulbxK8wotmviFR/Xzv/7I4yVP1bgDM7/Fp/W9OzS1DhG 5qbDjKESqBEDHssRMmKjAIejkKdbquW6DVhyFPVKrk639mgtz6WlAOzWUxnHLqxh/Bp3HTr6OS HhW/X9fD5IUXB1p33bqSNz6N3fSZoHoVY4LJG0au1aC5lQ==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:In-Reply-To:Content-Transfer-Encoding :Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID; bh=49EBDFGE5GJ2Zu6w+Cz/V5+oWvsVY5n80w3fjNVVyck=; b=MwyuDnU0Fe8w60ssDQ/MOBnEVa IefCK0+T1Y0IE2d5XS5CowpE3myAio48YAmxCEqlr1b9KYRC6r6U7N7WqBCIMThhelF++miqBIIwM mgkUV5iNl2e9npx1FMa5B/i8papIUvxL2MvXkWvpakRN/xMic9Ll0OGoLpcmJUH3n6iKz5XMxyY0h HEpVURm8QxzVXNKGVinSYbRXIMkACnbI2GYiKaV5l7V5L77Y/E+kwPjKZmTKpw6/aco9K84fQDugF EAwXeqkU3q6RJ4hqqqOIU6ood0h2tn/pllb/DIslBKjEgXYA8yem6583zZeZesOiDRGnKzd6SaLPq KcRfAwzA==; Received: by zero.zsh.org with local id 1owvHX-000POz-UB; Mon, 21 Nov 2022 01:07:31 +0000 Authentication-Results: zsh.org; iprev=pass (mail-oi1-f173.google.com) smtp.remote-ip=209.85.167.173; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-oi1-f173.google.com ([209.85.167.173]:43906) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1owvHH-000P3R-5C; Mon, 21 Nov 2022 01:07:16 +0000 Received: by mail-oi1-f173.google.com with SMTP id q83so11152685oib.10 for ; Sun, 20 Nov 2022 17:07:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:mail-followup-to:message-id:subject:cc:to :from:date:from:to:cc:subject:date:message-id:reply-to; bh=49EBDFGE5GJ2Zu6w+Cz/V5+oWvsVY5n80w3fjNVVyck=; b=qPGd6XulOuf/4NJJsz+HCqsmmd+bhBZ48hsQM/7sHsCjUzjHjDjWtLuxzHI8KDsXVv IlEdlChv4hZL8rQsKNAgy8lLsydjbE1T1urTQe7VzGxO9YcjuP6AAKKrmRaOojcNduhK Q3yzBbSMLE4xHH7nl9kzSQJJG/brPSnkhKJmmBtcREcLP2TLFtmGXZLajdHRZijviBnu 2vaxuPrWpKPbcX0GvZB66FvK1Wq2b060lGHkAK+B5eem04IEwjr1wOZTI4knacApINPu eCNd34YDdS1Z42AGrBKLrqtNZ0vL1frgSlkJb44dDE5AScojIlRHQDv1aV9mZwLws39f G56Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:mail-followup-to:message-id:subject:cc:to :from:date:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=49EBDFGE5GJ2Zu6w+Cz/V5+oWvsVY5n80w3fjNVVyck=; b=7g+oH5aAy1GTEKGFnua8si7QuSvP9XhFWmEk3rtxuz8MbIx3gD/BXSWIlbf1apnJye F8T4Y7Q2Z6pvf+cAuvrcRmfQiqfO9tRX6X6eaI6KQYAHvl1aNXv4rY9dA1rxjCwbOOqn ZSEn4g5Rj0C8GptYSE3hKI0szM0wKhn8iYFOE+J155rOutPmUX2Pklg0SzlM73GuQy+X WRTLetIevTtsmoiaxDlfyWOGGbaYd/iKqtRFkc0mS2xivMQ8CKfmhTMuSC03WFd9jfXk 8TO5FAIFNI5RGEelPvntGS3zhK4I1i6i2w5ZdghEu4iY6MGzfhK5CW/yQU019IOUXxyd juPg== X-Gm-Message-State: ANoB5pnz8p1WVh8ym530sViMeymXFeBv9/ymgylaR4CPeEiH5PQiXXc8 m2vQWYEC6uwZEIgqKhtVHvkAu1aWnv4= X-Google-Smtp-Source: AA0mqf7mrKx72qDhu0e4VtRdMpi0iApFlwFEUKgQV6YvOiz58x7+82NcGy3U4F1QriDy4Vs+oubRRQ== X-Received: by 2002:a05:6808:cc:b0:35a:639e:7125 with SMTP id t12-20020a05680800cc00b0035a639e7125mr7817097oic.167.1668992833584; Sun, 20 Nov 2022 17:07:13 -0800 (PST) Received: from CptOrmolo.darkstar (cpe-76-184-110-212.tx.res.rr.com. [76.184.110.212]) by smtp.gmail.com with ESMTPSA id a18-20020a056870d61200b0012b298699dbsm5322050oaq.1.2022.11.20.17.07.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 20 Nov 2022 17:07:12 -0800 (PST) Date: Sun, 20 Nov 2022 19:07:09 -0600 From: Matthew Martin To: Clinton Bunch Cc: zsh-workers@zsh.org Subject: Re: [PATCH] zsh/random module [UPDATED] Message-ID: Mail-Followup-To: Clinton Bunch , zsh-workers@zsh.org References: <741b77be-b679-76cc-f8ec-49c9d89323c1@zentaur.org> <1e8ea669-7a25-b321-6024-72dbc43ac023@zentaur.org> <41205a86-8aad-4821-baa4-1d2ac9bf3c5d@app.fastmail.com> <1b2cafe6-b4b5-c59a-11f3-4dbc1e99e2bc@zentaur.org> <6275a5ac-3a47-f591-7b3c-380ec4fed5ac@zentaur.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <6275a5ac-3a47-f591-7b3c-380ec4fed5ac@zentaur.org> X-Seq: 51003 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: On Mon, Nov 07, 2022 at 06:18:15PM -0600, Clinton Bunch wrote: > Here's the updated patch taking into account the feedback I got from Bart > and dana. > > -l length has been converted to -c count > > -L is placed before -U in the documentation > > Documentation specifies that -r (raw) is for binary data. > > Range checking has been added to the -L and -U options > > Bug where -i overrode -L or -U has been fixed.  Bounds take precedence even > if -i is redundantly specified. > > Default count has been changed to 1 if -i, -L, and/or -U has been specified > without -a > > dana's completion function has been updated with these changes and included > > A test file has been created (Not sure how useful it is, but it's there) I'm not clear on where the getrandom builtin came from. I understand the desire for SRANDOM to have a proper random source in the shell; however, the rest seems like feature creep that if necessary could be implemented with a loop. It seems prudent to keep the initial module to a minimum to ensure there's a usecase and so backwards compat concerns don't crop up. Would it suffice for your uses to have a module with just SRANDOM?