code
stringlengths
0
21.5M
repo_name
stringlengths
4
92
path
stringlengths
1
189
language
stringlengths
0
26
license
stringclasses
11 values
size
int64
0
21.5M
"""text_file provides the TextFile class, which gives an interface to text files that (optionally) takes care of stripping comments, ignoring blank lines, and joining lines with backslashes.""" import sys class TextFile: """Provides a file-like object that takes care of all the things you commonly want to d...
castiel248/Convert
Lib/site-packages/setuptools/_distutils/text_file.py
Python
mit
12,096
"""distutils.unixccompiler Contains the UnixCCompiler class, a subclass of CCompiler that handles the "typical" Unix-style command-line C compiler: * macros defined with -Dname[=value] * macros undefined with -Uname * include search directories specified with -Idir * libraries specified with -lllib * library...
castiel248/Convert
Lib/site-packages/setuptools/_distutils/unixccompiler.py
Python
mit
15,641
"""distutils.util Miscellaneous utility functions -- anything that doesn't fit into one of the other *util.py modules. """ import importlib.util import os import re import string import subprocess import sys import sysconfig import functools from distutils.errors import DistutilsPlatformError, DistutilsByteCompileEr...
castiel248/Convert
Lib/site-packages/setuptools/_distutils/util.py
Python
mit
18,128
# # distutils/version.py # # Implements multiple version numbering conventions for the # Python Module Distribution Utilities. # # $Id$ # """Provides classes to represent module version numbers (one class for each style of version numbering). There are currently two such classes implemented: StrictVersion and LooseVe...
castiel248/Convert
Lib/site-packages/setuptools/_distutils/version.py
Python
mit
12,952
"""Module for parsing and testing package version predicate strings. """ import re import distutils.version import operator re_validPackage = re.compile(r"(?i)^\s*([a-z_]\w*(?:\.[a-z_]\w*)*)(.*)", re.ASCII) # (package) (rest) re_paren = re.compile(r"^\s*\((.*)\)\s*$") # (list) inside of parentheses re_splitComparis...
castiel248/Convert
Lib/site-packages/setuptools/_distutils/versionpredicate.py
Python
mit
5,248
import functools import operator import itertools from .extern.jaraco.text import yield_lines from .extern.jaraco.functools import pass_none from ._importlib import metadata from ._itertools import ensure_unique from .extern.more_itertools import consume def ensure_valid(ep): """ Exercise one of the dynamic ...
castiel248/Convert
Lib/site-packages/setuptools/_entry_points.py
Python
mit
1,972
""" Re-implementation of find_module and get_frozen_object from the deprecated imp module. """ import os import importlib.util import importlib.machinery from .py34compat import module_from_spec PY_SOURCE = 1 PY_COMPILED = 2 C_EXTENSION = 3 C_BUILTIN = 6 PY_FROZEN = 7 def find_spec(module, paths): finder = ( ...
castiel248/Convert
Lib/site-packages/setuptools/_imp.py
Python
mit
2,392
import sys def disable_importlib_metadata_finder(metadata): """ Ensure importlib_metadata doesn't provide older, incompatible Distributions. Workaround for #3102. """ try: import importlib_metadata except ImportError: return except AttributeError: import warnin...
castiel248/Convert
Lib/site-packages/setuptools/_importlib.py
Python
mit
1,311
from setuptools.extern.more_itertools import consume # noqa: F401 # copied from jaraco.itertools 6.1 def ensure_unique(iterable, key=lambda x: x): """ Wrap an iterable to raise a ValueError if non-unique values are encountered. >>> list(ensure_unique('abc')) ['a', 'b', 'c'] >>> consume(ensure_un...
castiel248/Convert
Lib/site-packages/setuptools/_itertools.py
Python
mit
675
import os from typing import Union _Path = Union[str, os.PathLike] def ensure_directory(path): """Ensure that the parent directory of `path` exists""" dirname = os.path.dirname(path) os.makedirs(dirname, exist_ok=True) def same_path(p1: _Path, p2: _Path) -> bool: """Differs from os.path.samefile be...
castiel248/Convert
Lib/site-packages/setuptools/_path.py
Python
mit
749
import setuptools.extern.jaraco.text as text from pkg_resources import Requirement def parse_strings(strs): """ Yield requirement strings for each specification in `strs`. `strs` must be a string, or a (possibly-nested) iterable thereof. """ return text.join_continuation(map(text.drop_comment, t...
castiel248/Convert
Lib/site-packages/setuptools/_reqs.py
Python
mit
501
castiel248/Convert
Lib/site-packages/setuptools/_vendor/__init__.py
Python
mit
0
import os import re import abc import csv import sys from .. import zipp import email import pathlib import operator import textwrap import warnings import functools import itertools import posixpath import collections from . import _adapters, _meta from ._collections import FreezableDefaultDict, Pair from ._compat im...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/__init__.py
Python
mit
30,130
import re import textwrap import email.message from ._text import FoldedCase class Message(email.message.Message): multiple_use_keys = set( map( FoldedCase, [ 'Classifier', 'Obsoletes-Dist', 'Platform', 'Project-URL',...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_adapters.py
Python
mit
1,862
import collections # from jaraco.collections 3.3 class FreezableDefaultDict(collections.defaultdict): """ Often it is desirable to prevent the mutation of a default dict after its initial construction, such as to prevent mutation during iteration. >>> dd = FreezableDefaultDict(list) >>> dd[0]...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_collections.py
Python
mit
743
import sys import platform __all__ = ['install', 'NullFinder', 'Protocol'] try: from typing import Protocol except ImportError: # pragma: no cover from ..typing_extensions import Protocol # type: ignore def install(cls): """ Class decorator for installation on sys.meta_path. Adds the backpo...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_compat.py
Python
mit
1,828
import types import functools # from jaraco.functools 3.3 def method_cache(method, cache_wrapper=None): """ Wrap lru_cache to support storing the cache data in the object instances. Abstracts the common paradigm where the method explicitly saves an underscore-prefixed protected property on first call...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_functools.py
Python
mit
2,895
from itertools import filterfalse def unique_everseen(iterable, key=None): "List unique elements, preserving order. Remember all elements ever seen." # unique_everseen('AAAABBBCCDAABBB') --> A B C D # unique_everseen('ABBCcAD', str.lower) --> A B C D seen = set() seen_add = seen.add if key is ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_itertools.py
Python
mit
2,068
from ._compat import Protocol from typing import Any, Dict, Iterator, List, TypeVar, Union _T = TypeVar("_T") class PackageMetadata(Protocol): def __len__(self) -> int: ... # pragma: no cover def __contains__(self, item: str) -> bool: ... # pragma: no cover def __getitem__(self, key:...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_meta.py
Python
mit
1,154
import re from ._functools import method_cache # from jaraco.text 3.5 class FoldedCase(str): """ A case insensitive string class; behaves just like str except compares equal when the only variation is case. >>> s = FoldedCase('hello world') >>> s == 'Hello World' True >>> 'Hello World'...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_metadata/_text.py
Python
mit
2,166
"""Read resources contained within a package.""" from ._common import ( as_file, files, Package, ) from ._legacy import ( contents, open_binary, read_binary, open_text, read_text, is_resource, path, Resource, ) from .abc import ResourceReader __all__ = [ 'Package', ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/__init__.py
Python
mit
506
from contextlib import suppress from io import TextIOWrapper from . import abc class SpecLoaderAdapter: """ Adapt a package spec to adapt the underlying loader. """ def __init__(self, spec, adapter=lambda spec: spec.loader): self.spec = spec self.loader = adapter(spec) def __get...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/_adapters.py
Python
mit
4,504
import os import pathlib import tempfile import functools import contextlib import types import importlib from typing import Union, Optional from .abc import ResourceReader, Traversable from ._compat import wrap_spec Package = Union[types.ModuleType, str] def files(package): # type: (Package) -> Traversable ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/_common.py
Python
mit
2,741
# flake8: noqa import abc import sys import pathlib from contextlib import suppress if sys.version_info >= (3, 10): from zipfile import Path as ZipPath # type: ignore else: from ..zipp import Path as ZipPath # type: ignore try: from typing import runtime_checkable # type: ignore except ImportError: ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/_compat.py
Python
mit
2,706
from itertools import filterfalse from typing import ( Callable, Iterable, Iterator, Optional, Set, TypeVar, Union, ) # Type and type variable definitions _T = TypeVar('_T') _U = TypeVar('_U') def unique_everseen( iterable: Iterable[_T], key: Optional[Callable[[_T], _U]] = None ) -> ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/_itertools.py
Python
mit
884
import functools import os import pathlib import types import warnings from typing import Union, Iterable, ContextManager, BinaryIO, TextIO, Any from . import _common Package = Union[types.ModuleType, str] Resource = str def deprecated(func): @functools.wraps(func) def wrapper(*args, **kwargs): war...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/_legacy.py
Python
mit
3,494
import abc from typing import BinaryIO, Iterable, Text from ._compat import runtime_checkable, Protocol class ResourceReader(metaclass=abc.ABCMeta): """Abstract base class for loaders to provide resource reading support.""" @abc.abstractmethod def open_resource(self, resource: Text) -> BinaryIO: ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/abc.py
Python
mit
3,886
import collections import pathlib import operator from . import abc from ._itertools import unique_everseen from ._compat import ZipPath def remove_duplicates(items): return iter(collections.OrderedDict.fromkeys(items)) class FileReader(abc.TraversableResources): def __init__(self, loader): self.p...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/readers.py
Python
mit
3,566
""" Interface adapters for low-level readers. """ import abc import io import itertools from typing import BinaryIO, List from .abc import Traversable, TraversableResources class SimpleReader(abc.ABC): """ The minimum, low-level interface required from a resource provider. """ @abc.abstractprop...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/importlib_resources/simple.py
Python
mit
2,836
castiel248/Convert
Lib/site-packages/setuptools/_vendor/jaraco/__init__.py
Python
mit
0
import os import subprocess import contextlib import functools import tempfile import shutil import operator @contextlib.contextmanager def pushd(dir): orig = os.getcwd() os.chdir(dir) try: yield dir finally: os.chdir(orig) @contextlib.contextmanager def tarball_context(url, target_d...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/jaraco/context.py
Python
mit
5,420
import functools import time import inspect import collections import types import itertools import setuptools.extern.more_itertools from typing import Callable, TypeVar CallableT = TypeVar("CallableT", bound=Callable[..., object]) def compose(*funcs): """ Compose any number of unary functions into a sing...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/jaraco/functools.py
Python
mit
13,512
import re import itertools import textwrap import functools try: from importlib.resources import files # type: ignore except ImportError: # pragma: nocover from setuptools.extern.importlib_resources import files # type: ignore from setuptools.extern.jaraco.functools import compose, method_cache from setupt...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/jaraco/text/__init__.py
Python
mit
15,517
from .more import * # noqa from .recipes import * # noqa __version__ = '8.8.0'
castiel248/Convert
Lib/site-packages/setuptools/_vendor/more_itertools/__init__.py
Python
mit
82
import warnings from collections import Counter, defaultdict, deque, abc from collections.abc import Sequence from functools import partial, reduce, wraps from heapq import merge, heapify, heapreplace, heappop from itertools import ( chain, compress, count, cycle, dropwhile, groupby, islice...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/more_itertools/more.py
Python
mit
117,959
"""Imported from the recipes section of the itertools documentation. All functions taken from the recipes section of the itertools library docs [1]_. Some backward-compatible usability improvements have been made. .. [1] http://docs.python.org/library/itertools.html#recipes """ import warnings from collections impor...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/more_itertools/recipes.py
Python
mit
16,256
""" An OrderedSet is a custom MutableSet that remembers its order, so that every entry has an index that can be looked up. Based on a recipe originally posted to ActiveState Recipes by Raymond Hettiger, and released under the MIT license. """ import itertools as it from collections import deque try: # Python 3 ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/ordered_set.py
Python
mit
15,130
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. __all__ = [ "__title__", "__summary__", "__uri__", "__version__", "__author__", "__email__", "__license__", ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/__about__.py
Python
mit
661
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. from .__about__ import ( __author__, __copyright__, __email__, __license__, __summary__, __title__, __uri__, ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/__init__.py
Python
mit
497
import collections import functools import os import re import struct import sys import warnings from typing import IO, Dict, Iterator, NamedTuple, Optional, Tuple # Python does not provide platform information at sufficient granularity to # identify the architecture of the running executable in some cases, so we # d...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/_manylinux.py
Python
mit
11,488
"""PEP 656 support. This module implements logic to detect if the currently running Python is linked against musl, and what musl version is used. """ import contextlib import functools import operator import os import re import struct import subprocess import sys from typing import IO, Iterator, NamedTuple, Optional,...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/_musllinux.py
Python
mit
4,378
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. class InfinityType: def __repr__(self) -> str: return "Infinity" def __hash__(self) -> int: return hash(repr(self...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/_structures.py
Python
mit
1,431
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import operator import os import platform import sys from typing import Any, Callable, Dict, List, Optional, Tuple, Union from setuptools....
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/markers.py
Python
mit
8,493
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import re import string import urllib.parse from typing import List, Optional as TOptional, Set from setuptools.extern.pyparsing import ( ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/requirements.py
Python
mit
4,700
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import abc import functools import itertools import re import warnings from typing import ( Callable, Dict, Iterable, Itera...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/specifiers.py
Python
mit
30,110
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import logging import platform import sys import sysconfig from importlib.machinery import EXTENSION_SUFFIXES from typing import ( Dict...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/tags.py
Python
mit
15,699
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import re from typing import FrozenSet, NewType, Tuple, Union, cast from .tags import Tag, parse_tag from .version import InvalidVersion, ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/utils.py
Python
mit
4,200
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. import collections import itertools import re import warnings from typing import Callable, Iterator, List, Optional, SupportsInt, Tuple, Un...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/packaging/version.py
Python
mit
14,665
# module pyparsing.py # # Copyright (c) 2003-2022 Paul T. McGuire # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, cop...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/__init__.py
Python
mit
9,159
# actions.py from .exceptions import ParseException from .util import col class OnlyOnce: """ Wrapper for parse actions, to ensure they are only called once. """ def __init__(self, method_call): from .core import _trim_arity self.callable = _trim_arity(method_call) self.call...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/actions.py
Python
mit
6,426
# common.py from .core import * from .helpers import delimited_list, any_open_tag, any_close_tag from datetime import datetime # some other useful expressions - using lower-case class name since we are really using this as a namespace class pyparsing_common: """Here are some common low-level expressions that may ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/common.py
Python
mit
12,936
# # core.py # import os import typing from typing import ( NamedTuple, Union, Callable, Any, Generator, Tuple, List, TextIO, Set, Sequence, ) from abc import ABC, abstractmethod from enum import Enum import string import copy import warnings import re import sys from collections....
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/core.py
Python
mit
213,310
import railroad import pyparsing import typing from typing import ( List, NamedTuple, Generic, TypeVar, Dict, Callable, Set, Iterable, ) from jinja2 import Template from io import StringIO import inspect jinja2_template_source = """\ <!DOCTYPE html> <html> <head> {% if not head %} ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/diagram/__init__.py
Python
mit
23,668
# exceptions.py import re import sys import typing from .util import col, line, lineno, _collapse_string_to_ranges from .unicode import pyparsing_unicode as ppu class ExceptionWordUnicode(ppu.Latin1, ppu.LatinA, ppu.LatinB, ppu.Greek, ppu.Cyrillic): pass _extract_alphanums = _collapse_string_to_ranges(Excepti...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/exceptions.py
Python
mit
9,023
# helpers.py import html.entities import re import typing from . import __diag__ from .core import * from .util import _bslash, _flatten, _escape_regex_range_chars # # global helpers # def delimited_list( expr: Union[str, ParserElement], delim: Union[str, ParserElement] = ",", combine: bool = False, ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/helpers.py
Python
mit
39,129
# results.py from collections.abc import MutableMapping, Mapping, MutableSequence, Iterator import pprint from weakref import ref as wkref from typing import Tuple, Any str_type: Tuple[type, ...] = (str, bytes) _generator_type = type((_ for _ in ())) class _ParseResultsWithOffset: __slots__ = ["tup"] def __...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/results.py
Python
mit
25,341
# testing.py from contextlib import contextmanager import typing from .core import ( ParserElement, ParseException, Keyword, __diag__, __compat__, ) class pyparsing_test: """ namespace class for classes useful in writing unit tests """ class reset_pyparsing_context: """ ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/testing.py
Python
mit
13,402
# unicode.py import sys from itertools import filterfalse from typing import List, Tuple, Union class _lazyclassproperty: def __init__(self, fn): self.fn = fn self.__doc__ = fn.__doc__ self.__name__ = fn.__name__ def __get__(self, obj, cls): if cls is None: cls = ...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/unicode.py
Python
mit
10,787
# util.py import warnings import types import collections import itertools from functools import lru_cache from typing import List, Union, Iterable _bslash = chr(92) class __config_flags: """Internal class for defining compatibility and debugging flags""" _all_names: List[str] = [] _fixed_names: List[st...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/pyparsing/util.py
Python
mit
6,805
# SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: 2021 Taneli Hukkinen # Licensed to PSF under a Contributor Agreement. __all__ = ("loads", "load", "TOMLDecodeError") __version__ = "2.0.1" # DO NOT EDIT THIS LINE MANUALLY. LET bump2version UTILITY DO IT from ._parser import TOMLDecodeError, load, loads # Pre...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/tomli/__init__.py
Python
mit
396
# SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: 2021 Taneli Hukkinen # Licensed to PSF under a Contributor Agreement. from __future__ import annotations from collections.abc import Iterable import string from types import MappingProxyType from typing import Any, BinaryIO, NamedTuple from ._re import ( R...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/tomli/_parser.py
Python
mit
22,633
# SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: 2021 Taneli Hukkinen # Licensed to PSF under a Contributor Agreement. from __future__ import annotations from datetime import date, datetime, time, timedelta, timezone, tzinfo from functools import lru_cache import re from typing import Any from ._types import...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/tomli/_re.py
Python
mit
2,943
# SPDX-License-Identifier: MIT # SPDX-FileCopyrightText: 2021 Taneli Hukkinen # Licensed to PSF under a Contributor Agreement. from typing import Any, Callable, Tuple # Type annotations ParseFloat = Callable[[str], Any] Key = Tuple[str, ...] Pos = int
castiel248/Convert
Lib/site-packages/setuptools/_vendor/tomli/_types.py
Python
mit
254
import abc import collections import collections.abc import operator import sys import typing # After PEP 560, internal typing API was substantially reworked. # This is especially important for Protocol class which uses internal APIs # quite extensively. PEP_560 = sys.version_info[:3] >= (3, 7, 0) if PEP_560: Gen...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/typing_extensions.py
Python
mit
87,149
import io import posixpath import zipfile import itertools import contextlib import sys import pathlib if sys.version_info < (3, 7): from collections import OrderedDict else: OrderedDict = dict __all__ = ['Path'] def _parents(path): """ Given a path with elements separated by posixpath.sep, gen...
castiel248/Convert
Lib/site-packages/setuptools/_vendor/zipp.py
Python
mit
8,425
"""Utilities for extracting common archive formats""" import zipfile import tarfile import os import shutil import posixpath import contextlib from distutils.errors import DistutilsError from ._path import ensure_directory __all__ = [ "unpack_archive", "unpack_zipfile", "unpack_tarfile", "default_filter", "U...
castiel248/Convert
Lib/site-packages/setuptools/archive_util.py
Python
mit
7,346
"""A PEP 517 interface to setuptools Previously, when a user or a command line tool (let's call it a "frontend") needed to make a request of setuptools to take a certain action, for example, generating a list of installation requirements, the frontend would would call "setup.py egg_info" or "setup.py bdist_wheel" on t...
castiel248/Convert
Lib/site-packages/setuptools/build_meta.py
Python
mit
19,539
from distutils.command.bdist import bdist import sys if 'egg' not in bdist.format_commands: try: bdist.format_commands['egg'] = ('bdist_egg', "Python .egg file") except TypeError: # For backward compatibility with older distutils (stdlib) bdist.format_command['egg'] = ('bdist_egg', "Pyt...
castiel248/Convert
Lib/site-packages/setuptools/command/__init__.py
Python
mit
396
from distutils.errors import DistutilsOptionError from setuptools.command.setopt import edit_config, option_base, config_file def shquote(arg): """Quote an argument for later parsing by shlex.split()""" for c in '"', "'", "\\", "#": if c in arg: return repr(arg) if arg.split() != [arg...
castiel248/Convert
Lib/site-packages/setuptools/command/alias.py
Python
mit
2,381
"""setuptools.command.bdist_egg Build .egg distributions""" from distutils.dir_util import remove_tree, mkpath from distutils import log from types import CodeType import sys import os import re import textwrap import marshal from pkg_resources import get_build_platform, Distribution from setuptools.extension import...
castiel248/Convert
Lib/site-packages/setuptools/command/bdist_egg.py
Python
mit
16,623
import distutils.command.bdist_rpm as orig import warnings from setuptools import SetuptoolsDeprecationWarning class bdist_rpm(orig.bdist_rpm): """ Override the default bdist_rpm behavior to do the following: 1. Run egg_info to ensure the name and version are properly calculated. 2. Always run 'inst...
castiel248/Convert
Lib/site-packages/setuptools/command/bdist_rpm.py
Python
mit
1,182
import sys import warnings from typing import TYPE_CHECKING, List, Dict from distutils.command.build import build as _build from setuptools import SetuptoolsDeprecationWarning if sys.version_info >= (3, 8): from typing import Protocol elif TYPE_CHECKING: from typing_extensions import Protocol else: from a...
castiel248/Convert
Lib/site-packages/setuptools/command/build.py
Python
mit
6,595
import distutils.command.build_clib as orig from distutils.errors import DistutilsSetupError from distutils import log from setuptools.dep_util import newer_pairwise_group class build_clib(orig.build_clib): """ Override the default build_clib behaviour to do the following: 1. Implement a rudimentary time...
castiel248/Convert
Lib/site-packages/setuptools/command/build_clib.py
Python
mit
4,415
import os import sys import itertools from importlib.machinery import EXTENSION_SUFFIXES from importlib.util import cache_from_source as _compiled_file_name from typing import Dict, Iterator, List, Tuple from distutils.command.build_ext import build_ext as _du_build_ext from distutils.ccompiler import new_compiler fro...
castiel248/Convert
Lib/site-packages/setuptools/command/build_ext.py
Python
mit
15,821
from functools import partial from glob import glob from distutils.util import convert_path import distutils.command.build_py as orig import os import fnmatch import textwrap import io import distutils.errors import itertools import stat import warnings from pathlib import Path from typing import Dict, Iterable, Iterat...
castiel248/Convert
Lib/site-packages/setuptools/command/build_py.py
Python
mit
14,115
from distutils.util import convert_path from distutils import log from distutils.errors import DistutilsError, DistutilsOptionError import os import glob import io import pkg_resources from setuptools.command.easy_install import easy_install from setuptools import namespaces import setuptools class develop(namespace...
castiel248/Convert
Lib/site-packages/setuptools/command/develop.py
Python
mit
7,012
""" Create a dist_info directory As defined in the wheel specification """ import os import re import shutil import sys import warnings from contextlib import contextmanager from inspect import cleandoc from pathlib import Path from distutils.core import Command from distutils import log from setuptools.extern import...
castiel248/Convert
Lib/site-packages/setuptools/command/dist_info.py
Python
mit
4,800
""" Easy Install ------------ A tool for doing automatic download/extract/build of distutils-based Python packages. For detailed documentation, see the accompanying EasyInstall.txt file, or visit the `EasyInstall home page`__. __ https://setuptools.pypa.io/en/latest/deprecated/easy_install.html """ from glob impor...
castiel248/Convert
Lib/site-packages/setuptools/command/easy_install.py
Python
mit
85,662
""" Create a wheel that, when installed, will make the source package 'editable' (add it to the interpreter's path, including metadata) per PEP 660. Replaces 'setup.py develop'. .. note:: One of the mechanisms briefly mentioned in PEP 660 to implement editable installs is to create a separated directory inside `...
castiel248/Convert
Lib/site-packages/setuptools/command/editable_wheel.py
Python
mit
31,188
"""setuptools.command.egg_info Create a distribution's .egg-info directory and contents""" from distutils.filelist import FileList as _FileList from distutils.errors import DistutilsInternalError from distutils.util import convert_path from distutils import log import distutils.errors import distutils.filelist import...
castiel248/Convert
Lib/site-packages/setuptools/command/egg_info.py
Python
mit
26,795
from distutils.errors import DistutilsArgError import inspect import glob import warnings import platform import distutils.command.install as orig import setuptools # Prior to numpy 1.9, NumPy relies on the '_install' name, so provide it for # now. See https://github.com/pypa/setuptools/issues/199/ _install = orig.in...
castiel248/Convert
Lib/site-packages/setuptools/command/install.py
Python
mit
5,163
from distutils import log, dir_util import os from setuptools import Command from setuptools import namespaces from setuptools.archive_util import unpack_archive from .._path import ensure_directory import pkg_resources class install_egg_info(namespaces.Installer, Command): """Install an .egg-info directory for ...
castiel248/Convert
Lib/site-packages/setuptools/command/install_egg_info.py
Python
mit
2,226
import os import sys from itertools import product, starmap import distutils.command.install_lib as orig class install_lib(orig.install_lib): """Don't add compiled flags to filenames of non-Python files""" def run(self): self.build() outfiles = self.install() if outfiles is not None: ...
castiel248/Convert
Lib/site-packages/setuptools/command/install_lib.py
Python
mit
3,875
from distutils import log import distutils.command.install_scripts as orig from distutils.errors import DistutilsModuleError import os import sys from pkg_resources import Distribution, PathMetadata from .._path import ensure_directory class install_scripts(orig.install_scripts): """Do normal script install, plu...
castiel248/Convert
Lib/site-packages/setuptools/command/install_scripts.py
Python
mit
2,612
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"> <assemblyIdentity version="1.0.0.0" processorArchitecture="X86" name="%(name)s" type="win32"/> <!-- Identify the app...
castiel248/Convert
Lib/site-packages/setuptools/command/launcher manifest.xml
XML
mit
628
import os from glob import glob from distutils.util import convert_path from distutils.command import sdist class sdist_add_defaults: """ Mix-in providing forward-compatibility for functionality as found in distutils on Python 3.7. Do not edit the code in this class except to update functionality ...
castiel248/Convert
Lib/site-packages/setuptools/command/py36compat.py
Python
mit
4,946
from distutils import log import distutils.command.register as orig from setuptools.errors import RemovedCommandError class register(orig.register): """Formerly used to register packages on PyPI.""" def run(self): msg = ( "The register command has been removed, use twine to upload " ...
castiel248/Convert
Lib/site-packages/setuptools/command/register.py
Python
mit
468
from distutils.util import convert_path from distutils import log from distutils.errors import DistutilsOptionError import os import shutil from setuptools import Command class rotate(Command): """Delete older distributions""" description = "delete older distributions, keeping N newest files" user_optio...
castiel248/Convert
Lib/site-packages/setuptools/command/rotate.py
Python
mit
2,128
from setuptools.command.setopt import edit_config, option_base class saveopts(option_base): """Save command-line options to a file""" description = "save supplied options to setup.cfg or other config file" def run(self): dist = self.distribution settings = {} for cmd in dist.com...
castiel248/Convert
Lib/site-packages/setuptools/command/saveopts.py
Python
mit
658
from distutils import log import distutils.command.sdist as orig import os import sys import io import contextlib from itertools import chain from .py36compat import sdist_add_defaults from .._importlib import metadata from .build import _ORIGINAL_SUBCOMMANDS _default_revctrl = list def walk_revctrl(dirname=''): ...
castiel248/Convert
Lib/site-packages/setuptools/command/sdist.py
Python
mit
7,071
from distutils.util import convert_path from distutils import log from distutils.errors import DistutilsOptionError import distutils import os import configparser from setuptools import Command __all__ = ['config_file', 'edit_config', 'option_base', 'setopt'] def config_file(kind="local"): """Get the filename o...
castiel248/Convert
Lib/site-packages/setuptools/command/setopt.py
Python
mit
5,086
import os import operator import sys import contextlib import itertools import unittest from distutils.errors import DistutilsError, DistutilsOptionError from distutils import log from unittest import TestLoader from pkg_resources import ( resource_listdir, resource_exists, normalize_path, working_set,...
castiel248/Convert
Lib/site-packages/setuptools/command/test.py
Python
mit
8,102
from distutils import log from distutils.command import upload as orig from setuptools.errors import RemovedCommandError class upload(orig.upload): """Formerly used to upload packages to PyPI.""" def run(self): msg = ( "The upload command has been removed, use twine to upload " ...
castiel248/Convert
Lib/site-packages/setuptools/command/upload.py
Python
mit
462
# -*- coding: utf-8 -*- """upload_docs Implements a Distutils 'upload_docs' subcommand (upload documentation to sites other than PyPi such as devpi). """ from base64 import standard_b64encode from distutils import log from distutils.errors import DistutilsOptionError import os import socket import zipfile import temp...
castiel248/Convert
Lib/site-packages/setuptools/command/upload_docs.py
Python
mit
7,494
"""For backward compatibility, expose main functions from ``setuptools.config.setupcfg`` """ import warnings from functools import wraps from textwrap import dedent from typing import Callable, TypeVar, cast from .._deprecation_warning import SetuptoolsDeprecationWarning from . import setupcfg Fn = TypeVar("Fn", boun...
castiel248/Convert
Lib/site-packages/setuptools/config/__init__.py
Python
mit
1,121
"""Translation layer between pyproject config and setuptools distribution and metadata objects. The distribution and metadata objects are modeled after (an old version of) core metadata, therefore configs in the format specified for ``pyproject.toml`` need to be processed before being applied. **PRIVATE MODULE**: API...
castiel248/Convert
Lib/site-packages/setuptools/config/_apply_pyprojecttoml.py
Python
mit
13,398
from functools import reduce from typing import Any, Callable, Dict from . import formats from .error_reporting import detailed_errors, ValidationError from .extra_validations import EXTRA_VALIDATIONS from .fastjsonschema_exceptions import JsonSchemaException, JsonSchemaValueException from .fastjsonschema_validations ...
castiel248/Convert
Lib/site-packages/setuptools/config/_validate_pyproject/__init__.py
Python
mit
1,038
import io import json import logging import os import re from contextlib import contextmanager from textwrap import indent, wrap from typing import Any, Dict, Iterator, List, Optional, Sequence, Union, cast from .fastjsonschema_exceptions import JsonSchemaValueException _logger = logging.getLogger(__name__) _MESSAGE...
castiel248/Convert
Lib/site-packages/setuptools/config/_validate_pyproject/error_reporting.py
Python
mit
11,266
"""The purpose of this module is implement PEP 621 validations that are difficult to express as a JSON Schema (or that are not supported by the current JSON Schema library). """ from typing import Mapping, TypeVar from .error_reporting import ValidationError T = TypeVar("T", bound=Mapping) class RedefiningStaticFi...
castiel248/Convert
Lib/site-packages/setuptools/config/_validate_pyproject/extra_validations.py
Python
mit
1,153
import re SPLIT_RE = re.compile(r'[\.\[\]]+') class JsonSchemaException(ValueError): """ Base exception of ``fastjsonschema`` library. """ class JsonSchemaValueException(JsonSchemaException): """ Exception raised by validation function. Available properties: * ``message`` containing huma...
castiel248/Convert
Lib/site-packages/setuptools/config/_validate_pyproject/fastjsonschema_exceptions.py
Python
mit
1,612