Show More
@@ -0,0 +1,37 b'' | |||||
|
1 | IPython provides a rich toolkit to help you make the most out of using Python | |||
|
2 | interactively. Its main components are: | |||
|
3 | ||||
|
4 | * A powerful interactive Python shell | |||
|
5 | * A `Jupyter <https://jupyter.org/>`_ kernel to work with Python code in Jupyter | |||
|
6 | notebooks and other interactive frontends. | |||
|
7 | ||||
|
8 | The enhanced interactive Python shells have the following main features: | |||
|
9 | ||||
|
10 | * Comprehensive object introspection. | |||
|
11 | ||||
|
12 | * Input history, persistent across sessions. | |||
|
13 | ||||
|
14 | * Caching of output results during a session with automatically generated | |||
|
15 | references. | |||
|
16 | ||||
|
17 | * Extensible tab completion, with support by default for completion of python | |||
|
18 | variables and keywords, filenames and function keywords. | |||
|
19 | ||||
|
20 | * Extensible system of 'magic' commands for controlling the environment and | |||
|
21 | performing many tasks related either to IPython or the operating system. | |||
|
22 | ||||
|
23 | * A rich configuration system with easy switching between different setups | |||
|
24 | (simpler than changing $PYTHONSTARTUP environment variables every time). | |||
|
25 | ||||
|
26 | * Session logging and reloading. | |||
|
27 | ||||
|
28 | * Extensible syntax processing for special purpose situations. | |||
|
29 | ||||
|
30 | * Access to the system shell with user-extensible alias system. | |||
|
31 | ||||
|
32 | * Easily embeddable in other Python programs and GUIs. | |||
|
33 | ||||
|
34 | * Integrated access to the pdb debugger and the Python profiler. | |||
|
35 | ||||
|
36 | The latest development version is always available from IPython's `GitHub | |||
|
37 | site <http://github.com/ipython>`_. |
@@ -2,13 +2,13 b' include README.rst' | |||||
2 | include COPYING.rst |
|
2 | include COPYING.rst | |
3 | include LICENSE |
|
3 | include LICENSE | |
4 | include setupbase.py |
|
4 | include setupbase.py | |
5 | include setupegg.py |
|
|||
6 | include MANIFEST.in |
|
5 | include MANIFEST.in | |
7 | include pytest.ini |
|
6 | include pytest.ini | |
8 | include mypy.ini |
|
7 | include mypy.ini | |
9 | include .mailmap |
|
8 | include .mailmap | |
10 | include .flake8 |
|
9 | include .flake8 | |
11 | include .pre-commit-config.yaml |
|
10 | include .pre-commit-config.yaml | |
|
11 | include long_description.rst | |||
12 |
|
12 | |||
13 | recursive-exclude tools * |
|
13 | recursive-exclude tools * | |
14 | exclude tools |
|
14 | exclude tools |
@@ -4,44 +4,7 b' version = attr: IPython.core.release.__version__' | |||||
4 | url = https://ipython.org |
|
4 | url = https://ipython.org | |
5 | description = IPython: Productive Interactive Computing |
|
5 | description = IPython: Productive Interactive Computing | |
6 | long_description_content_type = text/x-rst |
|
6 | long_description_content_type = text/x-rst | |
7 | long_description = IPython provides a rich toolkit to help you make the most out of using Python |
|
7 | long_description = file: long_description.rst | |
8 | interactively. Its main components are: |
|
|||
9 |
|
||||
10 | * A powerful interactive Python shell |
|
|||
11 | * A `Jupyter <https://jupyter.org/>`_ kernel to work with Python code in Jupyter |
|
|||
12 | notebooks and other interactive frontends. |
|
|||
13 |
|
||||
14 | The enhanced interactive Python shells have the following main features: |
|
|||
15 |
|
||||
16 | * Comprehensive object introspection. |
|
|||
17 |
|
||||
18 | * Input history, persistent across sessions. |
|
|||
19 |
|
||||
20 | * Caching of output results during a session with automatically generated |
|
|||
21 | references. |
|
|||
22 |
|
||||
23 | * Extensible tab completion, with support by default for completion of python |
|
|||
24 | variables and keywords, filenames and function keywords. |
|
|||
25 |
|
||||
26 | * Extensible system of 'magic' commands for controlling the environment and |
|
|||
27 | performing many tasks related either to IPython or the operating system. |
|
|||
28 |
|
||||
29 | * A rich configuration system with easy switching between different setups |
|
|||
30 | (simpler than changing $PYTHONSTARTUP environment variables every time). |
|
|||
31 |
|
||||
32 | * Session logging and reloading. |
|
|||
33 |
|
||||
34 | * Extensible syntax processing for special purpose situations. |
|
|||
35 |
|
||||
36 | * Access to the system shell with user-extensible alias system. |
|
|||
37 |
|
||||
38 | * Easily embeddable in other Python programs and GUIs. |
|
|||
39 |
|
||||
40 | * Integrated access to the pdb debugger and the Python profiler. |
|
|||
41 |
|
||||
42 | The latest development version is always available from IPython's `GitHub |
|
|||
43 | site <http://github.com/ipython>`_. |
|
|||
44 |
|
||||
45 | license_file = LICENSE |
|
8 | license_file = LICENSE | |
46 | project_urls = |
|
9 | project_urls = | |
47 | Documentation = https://ipython.readthedocs.io/ |
|
10 | Documentation = https://ipython.readthedocs.io/ | |
@@ -58,7 +21,7 b' classifiers =' | |||||
58 | Programming Language :: Python |
|
21 | Programming Language :: Python | |
59 | Programming Language :: Python :: 3 |
|
22 | Programming Language :: Python :: 3 | |
60 | Programming Language :: Python :: 3 :: Only |
|
23 | Programming Language :: Python :: 3 :: Only | |
61 | Topic :: System :: Shell |
|
24 | Topic :: System :: Shells | |
62 |
|
25 | |||
63 |
|
26 | |||
64 | [options] |
|
27 | [options] |
@@ -3,9 +3,8 b'' | |||||
3 | """ |
|
3 | """ | |
4 | import os |
|
4 | import os | |
5 | import sys |
|
5 | import sys | |
6 | from shutil import rmtree |
|
|||
7 |
|
6 | |||
8 |
from toollib import sh, |
|
7 | from toollib import sh, get_ipdir, cd, build_command | |
9 |
|
8 | |||
10 | def build_release(): |
|
9 | def build_release(): | |
11 |
|
10 | |||
@@ -14,8 +13,8 b' def build_release():' | |||||
14 | cd(ipdir) |
|
13 | cd(ipdir) | |
15 |
|
14 | |||
16 | # Build source and binary distros |
|
15 | # Build source and binary distros | |
17 | sh(sdists) |
|
16 | sh(build_command) | |
18 | buildwheels() |
|
17 | # don't try to change, xz, bz2 deprecated. | |
19 | sh(' '.join([sys.executable, 'tools/retar.py', 'dist/*.gz'])) |
|
18 | sh(' '.join([sys.executable, 'tools/retar.py', 'dist/*.gz'])) | |
20 |
|
19 | |||
21 | if __name__ == '__main__': |
|
20 | if __name__ == '__main__': |
@@ -11,7 +11,7 b' from subprocess import call' | |||||
11 | import sys |
|
11 | import sys | |
12 |
|
12 | |||
13 | from toollib import (get_ipdir, pjoin, cd, execfile, sh, archive, |
|
13 | from toollib import (get_ipdir, pjoin, cd, execfile, sh, archive, | |
14 |
|
|
14 | archive_user, archive_dir) | |
15 | from gh_api import post_download |
|
15 | from gh_api import post_download | |
16 |
|
16 | |||
17 | # Get main ipython dir, this will raise if it doesn't pass some checks |
|
17 | # Get main ipython dir, this will raise if it doesn't pass some checks | |
@@ -63,7 +63,7 b" if 'upload' in sys.argv:" | |||||
63 | # Make target dir if it doesn't exist |
|
63 | # Make target dir if it doesn't exist | |
64 | print('1. Uploading IPython to archive.ipython.org') |
|
64 | print('1. Uploading IPython to archive.ipython.org') | |
65 | sh('ssh %s "mkdir -p %s/release/%s" ' % (archive_user, archive_dir, version)) |
|
65 | sh('ssh %s "mkdir -p %s/release/%s" ' % (archive_user, archive_dir, version)) | |
66 | sh('scp *.tar.gz *.whl %s' % release_site) |
|
66 | sh('scp *.tar.gz *.tar.xz *.whl %s' % release_site) | |
67 |
|
67 | |||
68 | print('2. Uploading backup files...') |
|
68 | print('2. Uploading backup files...') | |
69 | cd(ipbackupdir) |
|
69 | cd(ipbackupdir) | |
@@ -71,7 +71,7 b" if 'upload' in sys.argv:" | |||||
71 |
|
71 | |||
72 | print('3. Uploading to PyPI using twine') |
|
72 | print('3. Uploading to PyPI using twine') | |
73 | cd(distdir) |
|
73 | cd(distdir) | |
74 | call(['twine', 'upload'] + to_upload) |
|
74 | call(['twine', 'upload', '--verbose'] + to_upload) | |
75 |
|
75 | |||
76 | else: |
|
76 | else: | |
77 | # Build, but don't upload |
|
77 | # Build, but don't upload | |
@@ -85,7 +85,6 b' else:' | |||||
85 |
|
85 | |||
86 | cd(ipdir) |
|
86 | cd(ipdir) | |
87 |
|
87 | |||
88 | buildwheels() |
|
|||
89 | print("`./release upload` to upload source distribution on PyPI and ipython archive") |
|
88 | print("`./release upload` to upload source distribution on PyPI and ipython archive") | |
90 | sys.exit(0) |
|
89 | sys.exit(0) | |
91 |
|
90 |
@@ -35,7 +35,13 b' old_buf = io.BytesIO()' | |||||
35 | with open(path, "rb") as f: |
|
35 | with open(path, "rb") as f: | |
36 | old_buf.write(f.read()) |
|
36 | old_buf.write(f.read()) | |
37 | old_buf.seek(0) |
|
37 | old_buf.seek(0) | |
38 | old = tarfile.open(fileobj=old_buf, mode="r:gz") |
|
38 | if path.name.endswith("gz"): | |
|
39 | r_mode = "r:gz" | |||
|
40 | if path.name.endswith("bz2"): | |||
|
41 | r_mode = "r:bz2" | |||
|
42 | if path.name.endswith("xz"): | |||
|
43 | raise ValueError("XZ is deprecated but it's written nowhere") | |||
|
44 | old = tarfile.open(fileobj=old_buf, mode=r_mode) | |||
39 |
|
45 | |||
40 | buf = io.BytesIO() |
|
46 | buf = io.BytesIO() | |
41 | new = tarfile.open(fileobj=buf, mode="w", format=tarfile.GNU_FORMAT) |
|
47 | new = tarfile.open(fileobj=buf, mode="w", format=tarfile.GNU_FORMAT) | |
@@ -46,6 +52,7 b' for i, m in enumerate(old):' | |||||
46 | continue |
|
52 | continue | |
47 | m2 = tarfile.TarInfo(m.name) |
|
53 | m2 = tarfile.TarInfo(m.name) | |
48 | m2.mtime = min(timestamp, m.mtime) |
|
54 | m2.mtime = min(timestamp, m.mtime) | |
|
55 | m2.pax_headers["mtime"] = m2.mtime | |||
49 | m2.size = m.size |
|
56 | m2.size = m.size | |
50 | m2.type = m.type |
|
57 | m2.type = m.type | |
51 | m2.linkname = m.linkname |
|
58 | m2.linkname = m.linkname | |
@@ -59,9 +66,19 b' new.close()' | |||||
59 | old.close() |
|
66 | old.close() | |
60 |
|
67 | |||
61 | buf.seek(0) |
|
68 | buf.seek(0) | |
62 | with open(path, "wb") as f: |
|
69 | ||
63 | with gzip.GzipFile('', "wb", fileobj=f, mtime=timestamp) as gzf: |
|
70 | if r_mode == "r:gz": | |
64 | gzf.write(buf.read()) |
|
71 | with open(path, "wb") as f: | |
|
72 | with gzip.GzipFile("", "wb", fileobj=f, mtime=timestamp) as gzf: | |||
|
73 | gzf.write(buf.read()) | |||
|
74 | elif r_mode == "r:bz2": | |||
|
75 | import bz2 | |||
|
76 | ||||
|
77 | with bz2.open(path, "wb") as f: | |||
|
78 | f.write(buf.read()) | |||
|
79 | ||||
|
80 | else: | |||
|
81 | assert False | |||
65 |
|
82 | |||
66 | # checks the archive is valid. |
|
83 | # checks the archive is valid. | |
67 | archive = tarfile.open(path) |
|
84 | archive = tarfile.open(path) |
@@ -18,10 +18,8 b" archive = '%s:%s' % (archive_user, archive_dir)" | |||||
18 |
|
18 | |||
19 | # Build commands |
|
19 | # Build commands | |
20 | # Source dists |
|
20 | # Source dists | |
21 | sdists = './setup.py sdist --formats=gztar' |
|
21 | build_command = "{python} -m build".format(python=sys.executable) | |
22 | # Binary dists |
|
22 | ||
23 | def buildwheels(): |
|
|||
24 | sh('{python} setupegg.py bdist_wheel'.format(python=sys.executable)) |
|
|||
25 |
|
23 | |||
26 | # Utility functions |
|
24 | # Utility functions | |
27 | def sh(cmd): |
|
25 | def sh(cmd): |
General Comments 0
You need to be logged in to leave comments.
Login now