mirror of
https://github.com/chartjs/Chart.js.git
synced 2026-03-07 00:36:50 +01:00
Update release process to create versioned docs (#8817)
* Update release process to create versioned docs * Remove test, separate tag
This commit is contained in:
23
scripts/utils.sh
Normal file
23
scripts/utils.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
# tag is next|latest|master|x.x.x
|
||||
# https://www.chartjs.org/dist/$tag/
|
||||
# https://www.chartjs.org/docs/$tag/
|
||||
# https://www.chartjs.org/samples/$tag/
|
||||
function tag_from_version {
|
||||
local version=$1
|
||||
local mode=$2
|
||||
local tag=''
|
||||
if [ "$version" == "master" ]; then
|
||||
tag=master
|
||||
elif [[ "$version" =~ ^[^-]+$ ]]; then
|
||||
if [[ "$mode" == "release" ]]
|
||||
tag=$version
|
||||
else
|
||||
tag=latest
|
||||
fi
|
||||
else
|
||||
tag=next
|
||||
fi
|
||||
echo $tag
|
||||
}
|
||||
Reference in New Issue
Block a user