From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13008 invoked by alias); 20 Nov 2015 03:58:17 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 20971 Received: (qmail 26383 invoked from network); 20 Nov 2015 03:58:17 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.0 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= daniel.shahaf.name; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=AgYYjWbtvjmumCu1JV/U60b3Z5g=; b=dk1WIe rvDEFnH6kBb4J/4hWScvuJieb+x68ZLMSHvbnPOm9Sepm4sDJCwjuMdt8vxh1XHp dIHg7l9lwzfRh6cGiPAY9pCn9ndDUWMA7BqnAY8ClNaAF/sLphUAXG3pRlVZtA6t DpFZLYgroLfZVEjdMJKkIDMGpCWnngciGAIvE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=smtpout; bh=AgYYjWbtvjmumCu1JV/U60b3Z5g=; b=MBxK4 eoCew3wjBn9/emLHBTTX2ptZTPgVwD9CyoFfPWBzH3nsVrxdGlFcET9vZuhA9gJd vjx7Th8EfQ6mOUoy1NFQ3FrUR/meC5ZWXYSSqYSAz91O0NxHr7+pCl8DlHG7/Vrv 54wJ/PnEgwpjO4Rk4OSNLFNuu5a1WMfyMwwAJ4= X-Sasl-enc: 7GbqxMyiQ9oSWPikOFv+DwreV4BMpWo1Tg2xkOfwgvMH 1447991895 Date: Fri, 20 Nov 2015 03:58:13 +0000 From: Daniel Shahaf To: TJ Luoma Cc: Zsh-Users List Subject: Re: Version String Comparison Message-ID: <20151120035813.GE3955@tarsus.local2> References: <9A09EF7C-A81B-4ED9-A266-C6A53BC98167@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9A09EF7C-A81B-4ED9-A266-C6A53BC98167@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) TJ Luoma wrote on Thu, Nov 19, 2015 at 17:16:08 -0500: > > I am looking for a zsh way to compare version numbers, which is > smart enough to know that, for example > > "6.7.0.36" is less than "6.7.0.0044" If I didn't care about portability to other operating systems, I'd probably just use the package manager's version comparator: 'dpkg --compare-versions', 'pkg version --test-version', or local equivalent.