Skip to content

Commit 5a3b585

Browse files
committed
Update README: don't show --write CLI usage as the first suggestion
1 parent b306f1c commit 5a3b585

File tree

2 files changed

+23
-12
lines changed

2 files changed

+23
-12
lines changed

Makefile

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -167,18 +167,22 @@ fix-all: ## Run all code fixers.
167167
# Distribution
168168
# ===================================================================
169169

170-
check-manifest: ## Inspect MANIFEST.in file.
171-
$(PYTHON) -m check_manifest -v $(ARGS)
170+
check-manifest: ## Check sanity of MANIFEST.in file.
171+
$(PYTHON) -m check_manifest -v
172172

173-
sdist: ## Create tar.gz source distribution.
174-
${MAKE} generate-manifest
175-
$(PYTHON_ENV_VARS) $(PYTHON) setup.py sdist
176-
# Check sanity of source distribution.
173+
check-sdist: ## Check sanity of source distribution (must be created first).
177174
$(PYTHON_ENV_VARS) $(PYTHON) -m virtualenv --clear --no-wheel --quiet build/venv
178175
$(PYTHON_ENV_VARS) build/venv/bin/python -m pip install -v --isolated --quiet dist/*.tar.gz
179176
$(PYTHON_ENV_VARS) build/venv/bin/python -c "import os; os.chdir('build/venv'); import pyftpdlib"
180177
$(PYTHON) -m twine check --strict dist/*.tar.gz
181178

179+
generate-manifest: ## Generates MANIFEST.in file.
180+
$(PYTHON) scripts/internal/generate_manifest.py > MANIFEST.in
181+
182+
sdist: ## Create tar.gz source distribution.
183+
${MAKE} generate-manifest
184+
$(PYTHON_ENV_VARS) $(PYTHON) setup.py sdist
185+
182186
pre-release: ## All the necessary steps before making a release.
183187
${MAKE} clean
184188
${MAKE} check-manifest
@@ -196,9 +200,6 @@ release: ## Creates a release (tar.gz + upload + git tag release).
196200
$(PYTHON) -m twine upload dist/*.tar.gz # upload tar on PYPI
197201
${MAKE} git-tag-release
198202

199-
generate-manifest: ## Generates MANIFEST.in file.
200-
$(PYTHON) scripts/internal/generate_manifest.py > MANIFEST.in
201-
202203
git-tag-release: ## Git-tag a new release.
203204
git tag -a release-`$(PYTHON) -c "import pyftpdlib; print(pyftpdlib.__ver__)"` -m `git rev-list HEAD --count`:`git rev-parse --short HEAD`
204205
git push --follow-tags

README.rst

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,17 @@ For more benchmarks see `here <https://pyftpdlib.readthedocs.io/en/latest/benchm
144144
Command line usage
145145
==================
146146

147-
Start a FTP server, with an anonymous user with write permissions, on port 2121:
147+
Start an anonymous FTP server on port 2121:
148+
149+
.. code-block:: sh
150+
151+
$ python3 -m pyftpdlib
152+
[I 2024-06-23 13:49:35] concurrency model: async
153+
[I 2024-06-23 13:49:35] masquerade (NAT) address: None
154+
[I 2024-06-23 13:49:35] passive ports: None
155+
[I 2024-06-23 13:49:35] >>> starting FTP server on 0.0.0.0:2121, pid=763634 <<<
156+
157+
Same but with write permissions (useful to setup a quick and dirty file sharing server):
148158

149159
.. code-block:: sh
150160
@@ -154,10 +164,10 @@ Start a FTP server, with an anonymous user with write permissions, on port 2121:
154164
[I 2024-06-23 13:49:35] concurrency model: async
155165
[I 2024-06-23 13:49:35] masquerade (NAT) address: None
156166
[I 2024-06-23 13:49:35] passive ports: None
157-
[I 2024-06-23 13:49:35] >>> starting FTP server on 0.0.0.0:2121, pid=763634 <<<
167+
[I 2024-06-23 13:49:35] >>> starting FTP server on 0.0.0.0:2121, pid=763641 <<<
158168
159169
Also see `CLI doc <https://pyftpdlib.readthedocs.io/en/latest/cli.html>`__
160-
for more examples.
170+
for more command line examples.
161171

162172
API usage
163173
=========

0 commit comments

Comments
 (0)