Skip to content

Commit aba899c

Browse files
authored
patch bump (#2000)
1 parent 6a40e1c commit aba899c

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

mlx/version.h

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

55
#define MLX_VERSION_MAJOR 0
66
#define MLX_VERSION_MINOR 24
7-
#define MLX_VERSION_PATCH 0
7+
#define MLX_VERSION_PATCH 1
88
#define MLX_VERSION_NUMERIC \
99
(100000 * MLX_VERSION_MAJOR + 1000 * MLX_VERSION_MINOR + MLX_VERSION_PATCH)
1010

setup.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,16 @@
1212
from setuptools.command.build_ext import build_ext
1313

1414

15-
def get_version(version):
15+
def get_version():
16+
with open("mlx/version.h", "r") as fid:
17+
for l in fid:
18+
if "#define MLX_VERSION_MAJOR" in l:
19+
major = l.split()[-1]
20+
if "#define MLX_VERSION_MINOR" in l:
21+
minor = l.split()[-1]
22+
if "#define MLX_VERSION_PATCH" in l:
23+
patch = l.split()[-1]
24+
version = f"{major}.{minor}.{patch}"
1625
if "PYPI_RELEASE" not in os.environ:
1726
today = datetime.date.today()
1827
version = f"{version}.dev{today.year}{today.month:02d}{today.day:02d}"
@@ -172,7 +181,7 @@ def run(self) -> None:
172181

173182
setup(
174183
name="mlx",
175-
version=get_version("0.24.0"),
184+
version=get_version(),
176185
author="MLX Contributors",
177186
author_email="[email protected]",
178187
description="A framework for machine learning on Apple silicon.",

0 commit comments

Comments
 (0)