pystand 2.4__tar.gz → 2.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pystand-2.4 → pystand-2.6}/Makefile +1 -1
- {pystand-2.4/pystand.egg-info → pystand-2.6}/PKG-INFO +16 -9
- {pystand-2.4 → pystand-2.6}/README.md +15 -8
- {pystand-2.4 → pystand-2.6/pystand.egg-info}/PKG-INFO +16 -9
- {pystand-2.4 → pystand-2.6}/pystand.py +41 -11
- {pystand-2.4 → pystand-2.6}/.flake8 +0 -0
- {pystand-2.4 → pystand-2.6}/.gitignore +0 -0
- {pystand-2.4 → pystand-2.6}/pyproject.toml +0 -0
- {pystand-2.4 → pystand-2.6}/pystand.egg-info/SOURCES.txt +0 -0
- {pystand-2.4 → pystand-2.6}/pystand.egg-info/dependency_links.txt +0 -0
- {pystand-2.4 → pystand-2.6}/pystand.egg-info/entry_points.txt +0 -0
- {pystand-2.4 → pystand-2.6}/pystand.egg-info/requires.txt +0 -0
- {pystand-2.4 → pystand-2.6}/pystand.egg-info/top_level.txt +0 -0
- {pystand-2.4 → pystand-2.6}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: pystand
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.6
|
4
4
|
Summary: Install Python versions from python-build-standalone project
|
5
5
|
Author-email: Mark Blakeney <mark.blakeney@bullet-systems.net>
|
6
6
|
License: GPLv3
|
@@ -131,7 +131,7 @@ usage: pystand [-h] [-D DISTRIBUTION] [-P PREFIX_DIR] [-C CACHE_DIR]
|
|
131
131
|
[-M CACHE_MINUTES] [--purge-days PURGE_DAYS]
|
132
132
|
[--github-access-token GITHUB_ACCESS_TOKEN] [--no-strip]
|
133
133
|
[-V]
|
134
|
-
{install,update,remove,list,show,path} ...
|
134
|
+
{install,update,upgrade,remove,uninstall,list,show,path} ...
|
135
135
|
|
136
136
|
Command line tool to download, install, and update pre-built Python versions
|
137
137
|
from the python-build-standalone project at
|
@@ -164,18 +164,18 @@ options:
|
|
164
164
|
-V, --version just show pystand version
|
165
165
|
|
166
166
|
Commands:
|
167
|
-
{install,update,remove,list,show,path}
|
167
|
+
{install,update,upgrade,remove,uninstall,list,show,path}
|
168
168
|
install Install one or more versions from a python-build-
|
169
169
|
standalone release.
|
170
|
-
update
|
171
|
-
remove
|
170
|
+
update (upgrade) Update one, more, or all versions to another release.
|
171
|
+
remove (uninstall) Remove/uninstall one, more, or all versions.
|
172
172
|
list List installed versions and show which have an update
|
173
173
|
available.
|
174
174
|
show Show versions available from a release.
|
175
175
|
path Show path prefix to installed version base directory.
|
176
176
|
|
177
|
-
|
178
|
-
$HOME/.config/pystand-flags.conf.
|
177
|
+
Some commands offer aliases as shown in brackets above. Note you can set
|
178
|
+
default starting global options in $HOME/.config/pystand-flags.conf.
|
179
179
|
```
|
180
180
|
|
181
181
|
Type `pystand <command> -h` to see specific help/usage for any
|
@@ -184,7 +184,7 @@ individual command:
|
|
184
184
|
### Command `install`
|
185
185
|
|
186
186
|
```
|
187
|
-
usage: pystand install [-h] [-r RELEASE] [-f] version [version ...]
|
187
|
+
usage: pystand install [-h] [-r RELEASE] [-f] [-s] version [version ...]
|
188
188
|
|
189
189
|
Install one or more versions from a python-build-standalone release.
|
190
190
|
|
@@ -198,6 +198,8 @@ options:
|
|
198
198
|
YYYYMMDD release (e.g. 20240415), default is latest
|
199
199
|
release
|
200
200
|
-f, --force force install even if already installed
|
201
|
+
-s, --include-source also install source files if available in distribution
|
202
|
+
download
|
201
203
|
```
|
202
204
|
|
203
205
|
### Command `update`
|
@@ -220,6 +222,8 @@ options:
|
|
220
222
|
can be specified with --all)
|
221
223
|
-k, --keep keep old version after updating (but only if different
|
222
224
|
version number)
|
225
|
+
|
226
|
+
aliases: upgrade
|
223
227
|
```
|
224
228
|
|
225
229
|
### Command `remove`
|
@@ -240,6 +244,8 @@ options:
|
|
240
244
|
-r RELEASE, --release RELEASE
|
241
245
|
only remove versions if from specified YYYMMDD release
|
242
246
|
(e.g. 20240415)
|
247
|
+
|
248
|
+
aliases: uninstall
|
243
249
|
```
|
244
250
|
|
245
251
|
### Command `list`
|
@@ -266,7 +272,8 @@ options:
|
|
266
272
|
```
|
267
273
|
usage: pystand show [-h] [-r RELEASE] [-a] [re_match]
|
268
274
|
|
269
|
-
Show versions available from a release.
|
275
|
+
Show versions available from a release. View available releases and their
|
276
|
+
distributions at https://github.com/indygreg/python-build-standalone/releases.
|
270
277
|
|
271
278
|
positional arguments:
|
272
279
|
re_match show only versions+distributions matching this regular
|
@@ -114,7 +114,7 @@ usage: pystand [-h] [-D DISTRIBUTION] [-P PREFIX_DIR] [-C CACHE_DIR]
|
|
114
114
|
[-M CACHE_MINUTES] [--purge-days PURGE_DAYS]
|
115
115
|
[--github-access-token GITHUB_ACCESS_TOKEN] [--no-strip]
|
116
116
|
[-V]
|
117
|
-
{install,update,remove,list,show,path} ...
|
117
|
+
{install,update,upgrade,remove,uninstall,list,show,path} ...
|
118
118
|
|
119
119
|
Command line tool to download, install, and update pre-built Python versions
|
120
120
|
from the python-build-standalone project at
|
@@ -147,18 +147,18 @@ options:
|
|
147
147
|
-V, --version just show pystand version
|
148
148
|
|
149
149
|
Commands:
|
150
|
-
{install,update,remove,list,show,path}
|
150
|
+
{install,update,upgrade,remove,uninstall,list,show,path}
|
151
151
|
install Install one or more versions from a python-build-
|
152
152
|
standalone release.
|
153
|
-
update
|
154
|
-
remove
|
153
|
+
update (upgrade) Update one, more, or all versions to another release.
|
154
|
+
remove (uninstall) Remove/uninstall one, more, or all versions.
|
155
155
|
list List installed versions and show which have an update
|
156
156
|
available.
|
157
157
|
show Show versions available from a release.
|
158
158
|
path Show path prefix to installed version base directory.
|
159
159
|
|
160
|
-
|
161
|
-
$HOME/.config/pystand-flags.conf.
|
160
|
+
Some commands offer aliases as shown in brackets above. Note you can set
|
161
|
+
default starting global options in $HOME/.config/pystand-flags.conf.
|
162
162
|
```
|
163
163
|
|
164
164
|
Type `pystand <command> -h` to see specific help/usage for any
|
@@ -167,7 +167,7 @@ individual command:
|
|
167
167
|
### Command `install`
|
168
168
|
|
169
169
|
```
|
170
|
-
usage: pystand install [-h] [-r RELEASE] [-f] version [version ...]
|
170
|
+
usage: pystand install [-h] [-r RELEASE] [-f] [-s] version [version ...]
|
171
171
|
|
172
172
|
Install one or more versions from a python-build-standalone release.
|
173
173
|
|
@@ -181,6 +181,8 @@ options:
|
|
181
181
|
YYYYMMDD release (e.g. 20240415), default is latest
|
182
182
|
release
|
183
183
|
-f, --force force install even if already installed
|
184
|
+
-s, --include-source also install source files if available in distribution
|
185
|
+
download
|
184
186
|
```
|
185
187
|
|
186
188
|
### Command `update`
|
@@ -203,6 +205,8 @@ options:
|
|
203
205
|
can be specified with --all)
|
204
206
|
-k, --keep keep old version after updating (but only if different
|
205
207
|
version number)
|
208
|
+
|
209
|
+
aliases: upgrade
|
206
210
|
```
|
207
211
|
|
208
212
|
### Command `remove`
|
@@ -223,6 +227,8 @@ options:
|
|
223
227
|
-r RELEASE, --release RELEASE
|
224
228
|
only remove versions if from specified YYYMMDD release
|
225
229
|
(e.g. 20240415)
|
230
|
+
|
231
|
+
aliases: uninstall
|
226
232
|
```
|
227
233
|
|
228
234
|
### Command `list`
|
@@ -249,7 +255,8 @@ options:
|
|
249
255
|
```
|
250
256
|
usage: pystand show [-h] [-r RELEASE] [-a] [re_match]
|
251
257
|
|
252
|
-
Show versions available from a release.
|
258
|
+
Show versions available from a release. View available releases and their
|
259
|
+
distributions at https://github.com/indygreg/python-build-standalone/releases.
|
253
260
|
|
254
261
|
positional arguments:
|
255
262
|
re_match show only versions+distributions matching this regular
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: pystand
|
3
|
-
Version: 2.
|
3
|
+
Version: 2.6
|
4
4
|
Summary: Install Python versions from python-build-standalone project
|
5
5
|
Author-email: Mark Blakeney <mark.blakeney@bullet-systems.net>
|
6
6
|
License: GPLv3
|
@@ -131,7 +131,7 @@ usage: pystand [-h] [-D DISTRIBUTION] [-P PREFIX_DIR] [-C CACHE_DIR]
|
|
131
131
|
[-M CACHE_MINUTES] [--purge-days PURGE_DAYS]
|
132
132
|
[--github-access-token GITHUB_ACCESS_TOKEN] [--no-strip]
|
133
133
|
[-V]
|
134
|
-
{install,update,remove,list,show,path} ...
|
134
|
+
{install,update,upgrade,remove,uninstall,list,show,path} ...
|
135
135
|
|
136
136
|
Command line tool to download, install, and update pre-built Python versions
|
137
137
|
from the python-build-standalone project at
|
@@ -164,18 +164,18 @@ options:
|
|
164
164
|
-V, --version just show pystand version
|
165
165
|
|
166
166
|
Commands:
|
167
|
-
{install,update,remove,list,show,path}
|
167
|
+
{install,update,upgrade,remove,uninstall,list,show,path}
|
168
168
|
install Install one or more versions from a python-build-
|
169
169
|
standalone release.
|
170
|
-
update
|
171
|
-
remove
|
170
|
+
update (upgrade) Update one, more, or all versions to another release.
|
171
|
+
remove (uninstall) Remove/uninstall one, more, or all versions.
|
172
172
|
list List installed versions and show which have an update
|
173
173
|
available.
|
174
174
|
show Show versions available from a release.
|
175
175
|
path Show path prefix to installed version base directory.
|
176
176
|
|
177
|
-
|
178
|
-
$HOME/.config/pystand-flags.conf.
|
177
|
+
Some commands offer aliases as shown in brackets above. Note you can set
|
178
|
+
default starting global options in $HOME/.config/pystand-flags.conf.
|
179
179
|
```
|
180
180
|
|
181
181
|
Type `pystand <command> -h` to see specific help/usage for any
|
@@ -184,7 +184,7 @@ individual command:
|
|
184
184
|
### Command `install`
|
185
185
|
|
186
186
|
```
|
187
|
-
usage: pystand install [-h] [-r RELEASE] [-f] version [version ...]
|
187
|
+
usage: pystand install [-h] [-r RELEASE] [-f] [-s] version [version ...]
|
188
188
|
|
189
189
|
Install one or more versions from a python-build-standalone release.
|
190
190
|
|
@@ -198,6 +198,8 @@ options:
|
|
198
198
|
YYYYMMDD release (e.g. 20240415), default is latest
|
199
199
|
release
|
200
200
|
-f, --force force install even if already installed
|
201
|
+
-s, --include-source also install source files if available in distribution
|
202
|
+
download
|
201
203
|
```
|
202
204
|
|
203
205
|
### Command `update`
|
@@ -220,6 +222,8 @@ options:
|
|
220
222
|
can be specified with --all)
|
221
223
|
-k, --keep keep old version after updating (but only if different
|
222
224
|
version number)
|
225
|
+
|
226
|
+
aliases: upgrade
|
223
227
|
```
|
224
228
|
|
225
229
|
### Command `remove`
|
@@ -240,6 +244,8 @@ options:
|
|
240
244
|
-r RELEASE, --release RELEASE
|
241
245
|
only remove versions if from specified YYYMMDD release
|
242
246
|
(e.g. 20240415)
|
247
|
+
|
248
|
+
aliases: uninstall
|
243
249
|
```
|
244
250
|
|
245
251
|
### Command `list`
|
@@ -266,7 +272,8 @@ options:
|
|
266
272
|
```
|
267
273
|
usage: pystand show [-h] [-r RELEASE] [-a] [re_match]
|
268
274
|
|
269
|
-
Show versions available from a release.
|
275
|
+
Show versions available from a release. View available releases and their
|
276
|
+
distributions at https://github.com/indygreg/python-build-standalone/releases.
|
270
277
|
|
271
278
|
positional arguments:
|
272
279
|
re_match show only versions+distributions matching this regular
|
@@ -44,14 +44,14 @@ CNFFILE = platformdirs.user_config_path(f'{PROG}-flags.conf')
|
|
44
44
|
|
45
45
|
# Default distributions for various platforms
|
46
46
|
DISTRIBUTIONS = {
|
47
|
-
('Linux', 'x86_64'): '
|
47
|
+
('Linux', 'x86_64'): 'x86_64_v3-unknown-linux-gnu-install_only_stripped',
|
48
48
|
('Linux', 'aarch64'): 'aarch64-unknown-linux-gnu-install_only_stripped',
|
49
49
|
('Linux', 'armv7l'): 'armv7-unknown-linux-gnueabihf-install_only_stripped',
|
50
50
|
('Linux', 'armv8l'): 'armv7-unknown-linux-gnueabihf-install_only_stripped',
|
51
51
|
('Darwin', 'x86_64'): 'x86_64-apple-darwin-install_only_stripped',
|
52
52
|
('Darwin', 'aarch64'): 'aarch64-apple-darwin-install_only_stripped',
|
53
|
-
('Windows', 'x86_64'): 'x86_64-pc-windows-msvc-install_only_stripped',
|
54
|
-
('Windows', 'i686'): 'i686-pc-windows-msvc-install_only_stripped',
|
53
|
+
('Windows', 'x86_64'): 'x86_64-pc-windows-msvc-shared-install_only_stripped',
|
54
|
+
('Windows', 'i686'): 'i686-pc-windows-msvc-shared-install_only_stripped',
|
55
55
|
}
|
56
56
|
|
57
57
|
def is_admin() -> bool:
|
@@ -163,9 +163,19 @@ def fetch(args: Namespace, release: str, url: str, tdir: Path) -> str | None:
|
|
163
163
|
except Exception as e:
|
164
164
|
error = f'Failed to unpack "{url}": {e}'
|
165
165
|
else:
|
166
|
-
pdir = tmpdir / 'python'
|
167
|
-
|
168
|
-
|
166
|
+
pdir = tmpdir / 'python'
|
167
|
+
idir = pdir / 'install'
|
168
|
+
if idir.exists():
|
169
|
+
# This is a source distribution, copy the source if
|
170
|
+
# requested
|
171
|
+
if args.include_source:
|
172
|
+
srcdir = idir / 'src'
|
173
|
+
for subpath in pdir.iterdir():
|
174
|
+
if subpath.name != idir.name:
|
175
|
+
srcdir.mkdir(parents=True, exist_ok=True)
|
176
|
+
subpath.replace(srcdir / subpath.name)
|
177
|
+
|
178
|
+
pdir = idir
|
169
179
|
|
170
180
|
pdir.replace(tdir)
|
171
181
|
|
@@ -523,8 +533,9 @@ def main() -> str | None:
|
|
523
533
|
|
524
534
|
# Parse arguments
|
525
535
|
opt = ArgumentParser(description=__doc__,
|
526
|
-
|
527
|
-
|
536
|
+
epilog='Some commands offer aliases as shown in brackets above. '
|
537
|
+
'Note you can set default starting global options in '
|
538
|
+
f'{CNFFILE}.')
|
528
539
|
|
529
540
|
# Set up main/global arguments
|
530
541
|
opt.add_argument('-D', '--distribution',
|
@@ -565,8 +576,10 @@ def main() -> str | None:
|
|
565
576
|
else:
|
566
577
|
return f'Must define a docstring for command class "{name}".'
|
567
578
|
|
579
|
+
aliases = cls.aliases if hasattr(cls, 'aliases') else []
|
568
580
|
title = get_title(desc)
|
569
|
-
cmdopt = cmd.add_parser(name, description=desc, help=title
|
581
|
+
cmdopt = cmd.add_parser(name, description=desc, help=title,
|
582
|
+
aliases=aliases)
|
570
583
|
|
571
584
|
# Set up this commands own arguments, if it has any
|
572
585
|
if hasattr(cls, 'init'):
|
@@ -636,6 +649,9 @@ class _install(COMMAND):
|
|
636
649
|
'default is latest release')
|
637
650
|
parser.add_argument('-f', '--force', action='store_true',
|
638
651
|
help='force install even if already installed')
|
652
|
+
parser.add_argument('-s', '--include-source', action='store_true',
|
653
|
+
help='also install source files if available in '
|
654
|
+
'distribution download')
|
639
655
|
parser.add_argument('version', nargs='+',
|
640
656
|
help='version to install. E.g. 3.12 or 3.12.3')
|
641
657
|
|
@@ -666,6 +682,8 @@ class _install(COMMAND):
|
|
666
682
|
@COMMAND.add
|
667
683
|
class _update(COMMAND):
|
668
684
|
'Update one, more, or all versions to another release.'
|
685
|
+
aliases = ['upgrade']
|
686
|
+
|
669
687
|
@staticmethod
|
670
688
|
def init(parser: ArgumentParser) -> None:
|
671
689
|
parser.add_argument('-r', '--release',
|
@@ -692,7 +710,8 @@ class _update(COMMAND):
|
|
692
710
|
|
693
711
|
matcher = VersionMatcher(files)
|
694
712
|
for version in get_version_names(args):
|
695
|
-
|
713
|
+
vdir = args._versions / version
|
714
|
+
if not (data := get_json(vdir / args._data)):
|
696
715
|
continue
|
697
716
|
|
698
717
|
if (release := data.get('release')) == release_target:
|
@@ -719,6 +738,10 @@ class _update(COMMAND):
|
|
719
738
|
f'{fmt(nextver, release_target)} '
|
720
739
|
f'distribution="{distribution}" ..')
|
721
740
|
|
741
|
+
# If the source was originally included, then include it in
|
742
|
+
# the update.
|
743
|
+
args.include_source = (vdir / 'src').is_dir()
|
744
|
+
|
722
745
|
if error := install(args, new_vdir, release_target, distribution,
|
723
746
|
files):
|
724
747
|
return error
|
@@ -729,6 +752,8 @@ class _update(COMMAND):
|
|
729
752
|
@COMMAND.add
|
730
753
|
class _remove(COMMAND):
|
731
754
|
'Remove/uninstall one, more, or all versions.'
|
755
|
+
aliases = ['uninstall']
|
756
|
+
|
732
757
|
@staticmethod
|
733
758
|
def init(parser: ArgumentParser) -> None:
|
734
759
|
parser.add_argument('-a', '--all', action='store_true',
|
@@ -824,7 +849,12 @@ class _list(COMMAND):
|
|
824
849
|
|
825
850
|
@COMMAND.add
|
826
851
|
class _show(COMMAND):
|
827
|
-
'
|
852
|
+
'''
|
853
|
+
Show versions available from a release.
|
854
|
+
|
855
|
+
View available releases and their distributions at
|
856
|
+
https://github.com/indygreg/python-build-standalone/releases.
|
857
|
+
'''
|
828
858
|
@staticmethod
|
829
859
|
def init(parser: ArgumentParser) -> None:
|
830
860
|
parser.add_argument('-r', '--release',
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|