m-lib-defenc 1.1.1__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.
@@ -0,0 +1,33 @@
1
+ m_lib_defenc requires Python 2.7 or 3.4+.
2
+
3
+ Installation script setup.py requires setuptools.
4
+
5
+ Installation using pip:
6
+
7
+ System-wide:
8
+
9
+ sudo pip install m_lib_defenc
10
+
11
+ User mode:
12
+
13
+ pip install --user m_lib_defenc
14
+
15
+ Virtual environments:
16
+
17
+ pip install m_lib_defenc
18
+
19
+ Installation from sources:
20
+
21
+ To install the library from sources system-wide run run the following
22
+ command:
23
+
24
+ sudo python setup.py install
25
+
26
+ If you don't want to install it system-wide you can install it in your
27
+ home directory; run run the following command:
28
+
29
+ python setup.py install --user
30
+
31
+ Option '--user' installs m_lib_defenc into
32
+ $HOME/.local/lib/python$MAJOR.$MINOR/site-packages/ where python finds it
33
+ automatically.
@@ -0,0 +1,2 @@
1
+ global-include *.py *.txt
2
+ include MANIFEST.in Makefile mk-distr
@@ -0,0 +1,8 @@
1
+
2
+ .PHONY: distr
3
+ distr:
4
+ ./mk-distr
5
+
6
+ .PHONY: clean
7
+ clean:
8
+ find . -name '*.py[co]' -type f -delete
@@ -0,0 +1,35 @@
1
+ Metadata-Version: 2.1
2
+ Name: m_lib_defenc
3
+ Version: 1.1.1
4
+ Summary: Get default encoding
5
+ Home-page: https://phdru.name/Software/Python/#m_lib
6
+ Author: Oleg Broytman
7
+ Author-email: phd@phdru.name
8
+ License: GPL
9
+ Project-URL: Download, https://pypi.org/project/m_lib_defenc/
10
+ Project-URL: Git repo, https://git.phdru.name/m_lib_defenc.git/
11
+ Project-URL: Homepage, https://phdru.name/Software/Python/#m_lib
12
+ Description: Get default encoding. A part of Broytman Library for Python, Copyright (C) 1996-2025 PhiloSoft Design
13
+ Platform: Any
14
+ Classifier: Development Status :: 5 - Production/Stable
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: License :: OSI Approved :: GNU General Public License (GPL)
17
+ Classifier: Operating System :: OS Independent
18
+ Classifier: Programming Language :: Python :: 2
19
+ Classifier: Programming Language :: Python :: 2.7
20
+ Classifier: Programming Language :: Python :: 3
21
+ Classifier: Programming Language :: Python :: 3.4
22
+ Classifier: Programming Language :: Python :: 3.5
23
+ Classifier: Programming Language :: Python :: 3.6
24
+ Classifier: Programming Language :: Python :: 3.7
25
+ Classifier: Programming Language :: Python :: 3.8
26
+ Classifier: Programming Language :: Python :: 3.9
27
+ Classifier: Programming Language :: Python :: 3.10
28
+ Classifier: Programming Language :: Python :: 3.11
29
+ Classifier: Programming Language :: Python :: 3.12
30
+ Classifier: Programming Language :: Python :: 3.13
31
+ Classifier: Programming Language :: Python :: 3.14
32
+ Classifier: Topic :: Software Development :: Libraries
33
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
34
+ Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*
35
+ Description-Content-Type: text/plain
@@ -0,0 +1,12 @@
1
+ Broytman Library for Python.
2
+ Author: Oleg Broytman <phd@phdru.name>.
3
+ Copyright (C) 1996-2025 PhiloSoft Design.
4
+ License: GPL.
5
+
6
+ Content of the namespace package:
7
+
8
+ defenc.py - get default encoding.
9
+
10
+ ::
11
+
12
+ pip install m_lib_defenc
@@ -0,0 +1,6 @@
1
+ """Broytman Library for Python, Copyright (C) 1996-2025 PhiloSoft Design"""
2
+
3
+ try:
4
+ __import__('pkg_resources').declare_namespace(__name__)
5
+ except ImportError:
6
+ __path__ = __import__('pkgutil').extend_path(__path__, __name__)
@@ -0,0 +1,40 @@
1
+ #! /usr/bin/env python
2
+ """Get default encoding"""
3
+
4
+ from __future__ import print_function
5
+ import sys
6
+
7
+ try:
8
+ import locale
9
+ use_locale = True
10
+ except ImportError:
11
+ use_locale = False
12
+
13
+ __all__ = ['default_encoding']
14
+
15
+ if use_locale:
16
+ # Get the default charset.
17
+ try:
18
+ if sys.version_info[:2] < (3, 11):
19
+ lcAll = locale.getdefaultlocale()
20
+ else:
21
+ lcAll = []
22
+ except locale.Error as err:
23
+ print("WARNING:", err, file=sys.stderr)
24
+ lcAll = []
25
+
26
+ if len(lcAll) == 2 and lcAll[0] is not None:
27
+ default_encoding = lcAll[1]
28
+ else:
29
+ try:
30
+ default_encoding = locale.getpreferredencoding()
31
+ except locale.Error as err:
32
+ print("WARNING:", err, file=sys.stderr)
33
+ default_encoding = sys.getdefaultencoding()
34
+ else:
35
+ default_encoding = sys.getdefaultencoding()
36
+
37
+ default_encoding = default_encoding.lower()
38
+
39
+ if __name__ == "__main__":
40
+ print(default_encoding)
@@ -0,0 +1,35 @@
1
+ Metadata-Version: 2.1
2
+ Name: m-lib-defenc
3
+ Version: 1.1.1
4
+ Summary: Get default encoding
5
+ Home-page: https://phdru.name/Software/Python/#m_lib
6
+ Author: Oleg Broytman
7
+ Author-email: phd@phdru.name
8
+ License: GPL
9
+ Project-URL: Download, https://pypi.org/project/m_lib_defenc/
10
+ Project-URL: Git repo, https://git.phdru.name/m_lib_defenc.git/
11
+ Project-URL: Homepage, https://phdru.name/Software/Python/#m_lib
12
+ Description: Get default encoding. A part of Broytman Library for Python, Copyright (C) 1996-2025 PhiloSoft Design
13
+ Platform: Any
14
+ Classifier: Development Status :: 5 - Production/Stable
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: License :: OSI Approved :: GNU General Public License (GPL)
17
+ Classifier: Operating System :: OS Independent
18
+ Classifier: Programming Language :: Python :: 2
19
+ Classifier: Programming Language :: Python :: 2.7
20
+ Classifier: Programming Language :: Python :: 3
21
+ Classifier: Programming Language :: Python :: 3.4
22
+ Classifier: Programming Language :: Python :: 3.5
23
+ Classifier: Programming Language :: Python :: 3.6
24
+ Classifier: Programming Language :: Python :: 3.7
25
+ Classifier: Programming Language :: Python :: 3.8
26
+ Classifier: Programming Language :: Python :: 3.9
27
+ Classifier: Programming Language :: Python :: 3.10
28
+ Classifier: Programming Language :: Python :: 3.11
29
+ Classifier: Programming Language :: Python :: 3.12
30
+ Classifier: Programming Language :: Python :: 3.13
31
+ Classifier: Programming Language :: Python :: 3.14
32
+ Classifier: Topic :: Software Development :: Libraries
33
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
34
+ Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*
35
+ Description-Content-Type: text/plain
@@ -0,0 +1,14 @@
1
+ INSTALL.txt
2
+ MANIFEST.in
3
+ Makefile
4
+ README.txt
5
+ mk-distr
6
+ setup.cfg
7
+ setup.py
8
+ m_lib/__init__.py
9
+ m_lib/defenc.py
10
+ m_lib_defenc.egg-info/PKG-INFO
11
+ m_lib_defenc.egg-info/SOURCES.txt
12
+ m_lib_defenc.egg-info/dependency_links.txt
13
+ m_lib_defenc.egg-info/namespace_packages.txt
14
+ m_lib_defenc.egg-info/top_level.txt
@@ -0,0 +1,10 @@
1
+ #! /bin/sh
2
+
3
+ umask 022 &&
4
+
5
+ git archive --format=tar --prefix=m_lib_defenc/ "${1:-HEAD}" |
6
+ (cd "$HOME/tmp" && exec tar xf -) &&
7
+
8
+ cd "$HOME/tmp/m_lib_defenc" &&
9
+ python setup.py sdist --formats=bztar &&
10
+ cd dist && mv m_lib_defenc-*.tar.bz2 ../.. && cd ../.. && exec rm -rf m_lib_defenc
@@ -0,0 +1,8 @@
1
+ [easy_install]
2
+ optimize = 2
3
+
4
+ [egg_info]
5
+ tag_build =
6
+ tag_date = 0
7
+ tag_svn_revision = 0
8
+
@@ -0,0 +1,46 @@
1
+ #! /usr/bin/env python
2
+
3
+ from setuptools import setup
4
+
5
+ setup(
6
+ name = "m_lib_defenc",
7
+ version = "1.1.1",
8
+ description = "Get default encoding",
9
+ long_description = "Get default encoding. A part of Broytman Library for Python, Copyright (C) 1996-2025 PhiloSoft Design",
10
+ long_description_content_type="text/plain",
11
+ author = "Oleg Broytman",
12
+ author_email = "phd@phdru.name",
13
+ url = "https://phdru.name/Software/Python/#m_lib",
14
+ project_urls={
15
+ 'Homepage': 'https://phdru.name/Software/Python/#m_lib',
16
+ 'Download': 'https://pypi.org/project/m_lib_defenc/',
17
+ 'Git repo': 'https://git.phdru.name/m_lib_defenc.git/',
18
+ },
19
+ license = "GPL",
20
+ classifiers=[
21
+ 'Development Status :: 5 - Production/Stable',
22
+ 'Intended Audience :: Developers',
23
+ 'License :: OSI Approved :: GNU General Public License (GPL)',
24
+ 'Operating System :: OS Independent',
25
+ 'Programming Language :: Python :: 2',
26
+ 'Programming Language :: Python :: 2.7',
27
+ 'Programming Language :: Python :: 3',
28
+ 'Programming Language :: Python :: 3.4',
29
+ 'Programming Language :: Python :: 3.5',
30
+ 'Programming Language :: Python :: 3.6',
31
+ 'Programming Language :: Python :: 3.7',
32
+ 'Programming Language :: Python :: 3.8',
33
+ 'Programming Language :: Python :: 3.9',
34
+ 'Programming Language :: Python :: 3.10',
35
+ 'Programming Language :: Python :: 3.11',
36
+ 'Programming Language :: Python :: 3.12',
37
+ 'Programming Language :: Python :: 3.13',
38
+ 'Programming Language :: Python :: 3.14',
39
+ 'Topic :: Software Development :: Libraries',
40
+ 'Topic :: Software Development :: Libraries :: Python Modules',
41
+ ],
42
+ platforms = "Any",
43
+ packages = ["m_lib"],
44
+ namespace_packages = ["m_lib"],
45
+ python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*',
46
+ )