@@ -27,7 +27,7 @@ PACKAGE := mkdocstrings-python-xref
27
27
PACKAGE_VERSION_PATH := src/mkdocstrings_handlers/python_xref/VERSION
28
28
VERSION := $(strip $(file < $(PACKAGE_VERSION_PATH ) ) )
29
29
30
- SRC_FILES := $(wildcard src/mkdocstrings_handlers/garpy_python /* .py) $(PYTHON_VERSION_PATH )
30
+ SRC_FILES := $(wildcard src/mkdocstrings_handlers/python_xref /* .py) $(PYTHON_VERSION_PATH )
31
31
32
32
# Env names
33
33
DEV_ENV := mkxref-dev
@@ -145,17 +145,20 @@ lint: pylint mypy
145
145
WHEEL_FILE := dist/$(subst -,_,$(PACKAGE ) ) -$(VERSION ) -py3-none-any.whl
146
146
CONDA_FILE := dist/$(PACKAGE ) -$(VERSION ) -py_0.conda
147
147
148
+ build-sdist :
149
+ $(CONDA_RUN ) python -m build --sdist --no-isolation --outdir dist
150
+
148
151
$(WHEEL_FILE ) :
149
152
$(CONDA_RUN ) pip wheel . --no-deps --no-build-isolation -w dist
150
153
151
154
build-wheel : $(WHEEL_FILE )
152
155
153
156
$(CONDA_FILE ) : $(WHEEL_FILE )
154
- $(CONDA_RUN ) whl2conda build $(WHEEL_FILE )
157
+ $(CONDA_RUN ) whl2conda convert $(WHEEL_FILE )
155
158
156
159
build-conda : $(CONDA_FILE )
157
160
158
- build : build-wheel
161
+ build : build-wheel build-sdist build-conda
159
162
160
163
site/index.html : $(MKDOC_FILES ) $(SRC_FILES )
161
164
$(CONDA_RUN ) mkdocs build -f $(MKDOC_CONFIG )
@@ -193,16 +196,24 @@ doc-serve-all:
193
196
194
197
mike-serve : doc-serve-all
195
198
196
- check-upload :
197
- $(CONDA_RUN ) twine check $(WHEEL_FILE )
199
+ check-upload-wheel :
200
+ $(CONDA_RUN ) twine check dist/* .whl
201
+
202
+ check-upload-sdist :
203
+ $(CONDA_RUN ) twine check dist/* .tar.gz
204
+
205
+ check-upload : check-upload-sdist check-upload-wheel
206
+
207
+ upload-wheel : check-upload-wheel
208
+ # NOTE: --skip-existing doesn't seem to actually work
209
+ $(CONDA_RUN ) twine upload --skip-existing $(lastword $(sort $(wildcard dist/* .whl) ) )
210
+
198
211
199
- upload : check-upload
212
+ upload-sdist : check-upload-sdist
200
213
# NOTE: --skip-existing doesn't seem to actually work
201
- $(CONDA_RUN ) twine upload --skip-existing $(WHEEL_FILE )
214
+ $(CONDA_RUN ) twine upload --skip-existing $(lastword $( sort $( wildcard dist/ * .tar.gz) ) )
202
215
203
- anaconda-upload : $(CONDA_FILE )
204
- # you will need to log in first
205
- anaconda upload --user garpy $(CONDA_FILE )
216
+ upload : upload-sdist upload-wheel
206
217
207
218
clean-build :
208
219
-@$(RMDIR ) build
0 commit comments