mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-25 19:45:05 +08:00
Change regexp in install script to not take into acccount pre-releases
This commit is contained in:
parent
7a548467b9
commit
e291d9954a
@ -1,12 +1,12 @@
|
||||
#!/bin/sh
|
||||
|
||||
# COLORS
|
||||
RED="\033[31m"
|
||||
GREEN="\033[32m"
|
||||
DEFAULT="\033[0m"
|
||||
RED='\033[31m'
|
||||
GREEN='\033[32m'
|
||||
DEFAULT='\033[0m'
|
||||
|
||||
# GLOBALS
|
||||
REGEXP_SEMVER='v[^0-9]*\([0-9]*\)[.]\([0-9]*\)[.]\([0-9]*\)\([0-9A-Za-z-]*\)'
|
||||
GREP_SEMVER_REGEXP='\"v\([0-9]*\)[.]\([0-9]*\)[.]\([0-9]*\)\"' # i.e. "v[number].[number].[number]"
|
||||
BINARY_NAME='meilisearch'
|
||||
|
||||
# semverParseInto and semverLT from https://github.com/cloudflare/semver_bash/blob/master/semver.sh
|
||||
@ -103,7 +103,7 @@ esac
|
||||
|
||||
# GET LATEST VERSION
|
||||
tags=$(curl -s 'https://api.github.com/repos/meilisearch/MeiliSearch/tags' \
|
||||
| grep "$REGEXP_SEMVER" \
|
||||
| grep "$GREP_SEMVER_REGEXP" \
|
||||
| grep 'name' \
|
||||
| tr -d '"' | tr -d ',' | cut -d 'v' -f 2)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user