Skip to content

Commit 1f20187

Browse files
authored
Bump to v0.6.4 (#891)
1 parent d1f8124 commit 1f20187

File tree

5 files changed

+16
-7
lines changed

5 files changed

+16
-7
lines changed

budoux/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
from . import parser
1717

18-
__version__ = "0.6.3"
18+
__version__ = "0.6.4"
1919

2020
Parser = parser.Parser
2121
load_default_japanese_parser = parser.load_default_japanese_parser

bump_version.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
# limitations under the License.
1414

1515
import argparse
16+
import json
1617
import re
1718
import subprocess
1819

@@ -34,8 +35,16 @@ def main():
3435
f.write(new_content)
3536

3637
# Updates JavaScript port version number
37-
npm_command = ['npm', 'version', new_version, '--no-git-tag-version']
38-
subprocess.run(npm_command, cwd='javascript', check=True)
38+
package_json_path = 'javascript/package.json'
39+
with open(package_json_path, 'r') as f:
40+
package_data = json.load(f)
41+
current_version = package_data.get('version')
42+
43+
if current_version != new_version:
44+
npm_command = ['npm', 'version', new_version, '--no-git-tag-version']
45+
subprocess.run(npm_command, cwd='javascript', check=True)
46+
else:
47+
print(f"JavaScript version is already {new_version}, skipping npm version.")
3948

4049
cli_file = 'javascript/src/cli.ts'
4150
with open(cli_file, 'r') as f:

javascript/package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

javascript/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "budoux",
3-
"version": "0.6.3",
3+
"version": "0.6.4",
44
"description": "A small chunk segmenter.",
55
"repository": {
66
"type": "git",

javascript/src/cli.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import {
2424
loadDefaultJapaneseParser,
2525
} from './index.js';
2626

27-
const CLI_VERSION = '0.6.3';
27+
const CLI_VERSION = '0.6.4';
2828
const defaultParsers = loadDefaultParsers();
2929

3030
/**

0 commit comments

Comments
 (0)