Elffuss BraidHub

kikocis/lancedb public

b5f7336ae52e · 3.4 KiBRawPermalink
1[tool.bumpversion]
2current_version = "0.11.1-beta.1"
3parse = """(?x)
4 (?P<major>0|[1-9]\\d*)\\.
5 (?P<minor>0|[1-9]\\d*)\\.
6 (?P<patch>0|[1-9]\\d*)
7 (?:-(?P<pre_l>[a-zA-Z-]+)\\.(?P<pre_n>0|[1-9]\\d*))?
8"""
9serialize = [
10 "{major}.{minor}.{patch}-{pre_l}.{pre_n}",
11 "{major}.{minor}.{patch}",
12]
13search = "{current_version}"
14replace = "{new_version}"
15regex = false
16ignore_missing_version = false
17ignore_missing_files = false
18tag = true
19sign_tags = false
20tag_name = "v{new_version}"
21tag_message = "Bump version: {current_version} → {new_version}"
22allow_dirty = true
23commit = true
24message = "Bump version: {current_version} → {new_version}"
25commit_args = ""
26
27# Java maven files
28pre_commit_hooks = [
29 """
30 NEW_VERSION="${BVHOOK_NEW_MAJOR}.${BVHOOK_NEW_MINOR}.${BVHOOK_NEW_PATCH}"
31 if [ ! -z "$BVHOOK_NEW_PRE_L" ] && [ ! -z "$BVHOOK_NEW_PRE_N" ]; then
32 NEW_VERSION="${NEW_VERSION}-${BVHOOK_NEW_PRE_L}.${BVHOOK_NEW_PRE_N}"
33 fi
34 echo "Constructed new version: $NEW_VERSION"
35 cd java && mvn versions:set -DnewVersion=$NEW_VERSION && mvn versions:commit
36
37 # Check for any modified but unstaged pom.xml files
38 MODIFIED_POMS=$(git ls-files -m | grep pom.xml)
39 if [ ! -z "$MODIFIED_POMS" ]; then
40 echo "The following pom.xml files were modified but not staged. Adding them now:"
41 echo "$MODIFIED_POMS" | while read -r file; do
42 git add "$file"
43 echo "Added: $file"
44 done
45 fi
46 """,
47]
48
49[tool.bumpversion.parts.pre_l]
50optional_value = "final"
51values = ["beta", "final"]
52
53[[tool.bumpversion.files]]
54filename = "node/package.json"
55replace = "\"version\": \"{new_version}\","
56search = "\"version\": \"{current_version}\","
57
58[[tool.bumpversion.files]]
59filename = "nodejs/package.json"
60replace = "\"version\": \"{new_version}\","
61search = "\"version\": \"{current_version}\","
62
63# nodejs binary packages
64[[tool.bumpversion.files]]
65glob = "nodejs/npm/*/package.json"
66replace = "\"version\": \"{new_version}\","
67search = "\"version\": \"{current_version}\","
68
69# vectodb node binary packages
70[[tool.bumpversion.files]]
71glob = "node/package.json"
72replace = "\"@lancedb/vectordb-darwin-arm64\": \"{new_version}\""
73search = "\"@lancedb/vectordb-darwin-arm64\": \"{current_version}\""
74
75[[tool.bumpversion.files]]
76glob = "node/package.json"
77replace = "\"@lancedb/vectordb-darwin-x64\": \"{new_version}\""
78search = "\"@lancedb/vectordb-darwin-x64\": \"{current_version}\""
79
80[[tool.bumpversion.files]]
81glob = "node/package.json"
82replace = "\"@lancedb/vectordb-linux-arm64-gnu\": \"{new_version}\""
83search = "\"@lancedb/vectordb-linux-arm64-gnu\": \"{current_version}\""
84
85[[tool.bumpversion.files]]
86glob = "node/package.json"
87replace = "\"@lancedb/vectordb-linux-x64-gnu\": \"{new_version}\""
88search = "\"@lancedb/vectordb-linux-x64-gnu\": \"{current_version}\""
89
90[[tool.bumpversion.files]]
91glob = "node/package.json"
92replace = "\"@lancedb/vectordb-win32-x64-msvc\": \"{new_version}\""
93search = "\"@lancedb/vectordb-win32-x64-msvc\": \"{current_version}\""
94
95# Cargo files
96# ------------
97[[tool.bumpversion.files]]
98filename = "rust/ffi/node/Cargo.toml"
99replace = "\nversion = \"{new_version}\""
100search = "\nversion = \"{current_version}\""
101
102[[tool.bumpversion.files]]
103filename = "rust/lancedb/Cargo.toml"
104replace = "\nversion = \"{new_version}\""
105search = "\nversion = \"{current_version}\""
106
107[[tool.bumpversion.files]]
108filename = "nodejs/Cargo.toml"
109replace = "\nversion = \"{new_version}\""
110search = "\nversion = \"{current_version}\""