Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Version String Comparison
- X-seq: zsh-users 20971
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: TJ Luoma <luomat@xxxxxxxxx>
- Subject: Re: Version String Comparison
- Date: Fri, 20 Nov 2015 03:58:13 +0000
- Cc: Zsh-Users List <zsh-users@xxxxxxx>
- 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=
- In-reply-to: <9A09EF7C-A81B-4ED9-A266-C6A53BC98167@gmail.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <9A09EF7C-A81B-4ED9-A266-C6A53BC98167@gmail.com>
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.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author