From b0547bb6adc09b2be1b2e228e5e941b1fc19c324 Mon Sep 17 00:00:00 2001
From: Bhavek Budhia <bhavek.budhia@boldcommerce.com>
Date: Mon, 1 Mar 2021 12:40:16 -0600
Subject: [PATCH] Added instructions on how to upload to PyPi

* Added a docs/upload-to-pypi.md file
* Added the setup.cfg file
* Updated setup.py: Added version, license and url meta information
---
 .pypirc                                       |   2 +
 .../PKG-INFO                                  | 100 ++++++++++++++++++
 .../SOURCES.txt                               |  33 ++++++
 .../dependency_links.txt                      |   1 +
 .../entry_points.txt                          |   3 +
 .../requires.txt                              |  13 +++
 .../top_level.txt                             |   1 +
 docs/upload-to-pypi.md                        |  34 ++++++
 setup.cfg                                     |   4 +
 setup.py                                      |  15 ++-
 10 files changed, 204 insertions(+), 2 deletions(-)
 create mode 100644 .pypirc
 create mode 100644 Bold_Composer_Version_Manager.egg-info/PKG-INFO
 create mode 100644 Bold_Composer_Version_Manager.egg-info/SOURCES.txt
 create mode 100644 Bold_Composer_Version_Manager.egg-info/dependency_links.txt
 create mode 100644 Bold_Composer_Version_Manager.egg-info/entry_points.txt
 create mode 100644 Bold_Composer_Version_Manager.egg-info/requires.txt
 create mode 100644 Bold_Composer_Version_Manager.egg-info/top_level.txt
 create mode 100644 docs/upload-to-pypi.md
 create mode 100644 setup.cfg

diff --git a/.pypirc b/.pypirc
new file mode 100644
index 0000000..f8e09a4
--- /dev/null
+++ b/.pypirc
@@ -0,0 +1,2 @@
+[testpypi]
+username=bhavek
\ No newline at end of file
diff --git a/Bold_Composer_Version_Manager.egg-info/PKG-INFO b/Bold_Composer_Version_Manager.egg-info/PKG-INFO
new file mode 100644
index 0000000..bca1467
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/PKG-INFO
@@ -0,0 +1,100 @@
+Metadata-Version: 2.1
+Name: Bold-Composer-Version-Manager
+Version: 1.0.6
+Summary: UNKNOWN
+Home-page: https://github.com/composer-version-manager/cvm
+License: MIT
+Description: # Composer Version Manager
+        
+        [Composer 2](https://getcomposer.org/upgrade/UPGRADE-2.0.md) is here. It's time for a one stop shop for switching between major (and minor 
+        👶) composer versions. Erase "using the right composer version" from your workflow.
+        
+        > But wait, what about `composer self-update --1` and `--2`?
+        
+        Well I'm glad you've asked!
+        
+        There are some added benefits this CLI and shell hook will bring to you:
+        
+        1. Cached `composer.phar` for faster version toggling.
+        1. Per-directory smart composer environments. It's as simple as `cd my-project` and the right composer version will be used.
+        
+        ## Installation
+        
+        Choose one of the options below to install cvm.
+        
+        ### Homebrew (MacOS)
+        
+        ```bash
+        brew update
+        brew install composer-version-manager/cvm/cvm
+        ```
+        
+        **Note:** Watch for symlink errors. If you already have an existing `Python3` installation you may be required to run the following command:
+        
+        ```bash
+        brew link --overwrite cvm
+        ```
+        
+        ### Chocolatey (Windows)
+        
+        *TODO*
+        
+        ### Download binary and update PATH
+        
+        *TODO*
+        
+        ## Hook onto your shell
+        
+        Hooking onto your shell enables cvm [Smart usage](#smart-usage) for per-directory automated composer verrsioning.
+        
+        Find the instructions for your shell below. If your shell is not listed please feel free to [submit a feature request](https://github.com/composer-version-manager/cvm/issues/new) issue and we will try and make it happen.
+        
+        ### **BASH**
+        
+        Add the following line to the end of your `~/.bashrc`
+        
+        ```bash
+        eval "$(cvm hook bash)"
+        ```
+        
+        ### **ZSH**
+        
+        Add the following line to the end of your `~/.zshrc`
+        
+        ```bash
+        eval "$(cvm hook zsh)"
+        ```
+        
+        ## Smart usage
+        
+        Create a `.cvm_config` in any directory specifying the composer version you would like to use. Navigating to that directory or any nested directory will automatically enable that composer version in your current workspace.
+        
+        ```bash
+        cd my-project
+        echo '2.0.11' > .cvm_config
+        ```
+        
+        This file can be committed to your source control.
+        
+        ## Global composer version
+        
+        You can configure a global composer version. Which will be the default when no parent directory has a `.cvm_config`.
+        
+        ```
+        cvm list        # List available tags
+        cvm use 2.0.11  # Globally use a specific composer version
+        ```
+        
+        ## Authors
+        
+        ### Morgan Wowk
+        
+        Morgan is a Software Developer from the wintery lands of Canada 🇨🇦🍁. You can primarily find him on [LinkedIn](https://www.linkedin.com/in/morganwowk/), writing open source or building apps to help [tens of thousands of ecommerce stores](https://boldcommerce.com/).
+        
+        ### Bhavek Budhia
+        
+        Likewise, Bhavek resides in the frosty country of Canada ☃️. An avid developer 👨‍💻 with fortified experience in Python that has helped us develop a clean and extendable codebase.
+        
+Platform: UNKNOWN
+Requires-Python: >=3
+Description-Content-Type: text/markdown
diff --git a/Bold_Composer_Version_Manager.egg-info/SOURCES.txt b/Bold_Composer_Version_Manager.egg-info/SOURCES.txt
new file mode 100644
index 0000000..4427986
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/SOURCES.txt
@@ -0,0 +1,33 @@
+README.md
+setup.cfg
+setup.py
+Bold_Composer_Version_Manager.egg-info/PKG-INFO
+Bold_Composer_Version_Manager.egg-info/SOURCES.txt
+Bold_Composer_Version_Manager.egg-info/dependency_links.txt
+Bold_Composer_Version_Manager.egg-info/entry_points.txt
+Bold_Composer_Version_Manager.egg-info/requires.txt
+Bold_Composer_Version_Manager.egg-info/top_level.txt
+cvm/__init__.py
+cvm/cli.py
+cvm/commands.bkup.py
+cvm/commands/__init__.py
+cvm/commands/cache_command.py
+cvm/commands/command.py
+cvm/commands/hook_command.py
+cvm/commands/list_command.py
+cvm/commands/scan_command.py
+cvm/commands/use_command.py
+cvm/helpers/__init__.py
+cvm/helpers/cli.py
+cvm/helpers/fs.py
+cvm/services/__init__.py
+cvm/services/application_service.py
+cvm/services/cache_service.py
+cvm/services/composer_service.py
+cvm/services/config_service.py
+cvm/services/github_service.py
+cvm/services/shell_service.py
+cvm/shells/__init__.py
+cvm/shells/shell.py
+cvm/shells/shell_bash.py
+cvm/shells/shell_zsh.py
\ No newline at end of file
diff --git a/Bold_Composer_Version_Manager.egg-info/dependency_links.txt b/Bold_Composer_Version_Manager.egg-info/dependency_links.txt
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/dependency_links.txt
@@ -0,0 +1 @@
+
diff --git a/Bold_Composer_Version_Manager.egg-info/entry_points.txt b/Bold_Composer_Version_Manager.egg-info/entry_points.txt
new file mode 100644
index 0000000..96c9f90
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/entry_points.txt
@@ -0,0 +1,3 @@
+[console_scripts]
+cvm = cvm.cli:main
+
diff --git a/Bold_Composer_Version_Manager.egg-info/requires.txt b/Bold_Composer_Version_Manager.egg-info/requires.txt
new file mode 100644
index 0000000..4bdd7ba
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/requires.txt
@@ -0,0 +1,13 @@
+ansicolors==1.1.8
+argparse-color-formatter==1.2.2.post2
+certifi==2020.12.5
+chardet==4.0.0
+colorama==0.4.4
+idna==2.10
+mypy==0.790
+mypy-extensions==0.4.3
+requests==2.25.1
+six==1.15.0
+typed-ast==1.4.2
+typing-extensions==3.7.4.3
+urllib3==1.26.2
diff --git a/Bold_Composer_Version_Manager.egg-info/top_level.txt b/Bold_Composer_Version_Manager.egg-info/top_level.txt
new file mode 100644
index 0000000..93e5faa
--- /dev/null
+++ b/Bold_Composer_Version_Manager.egg-info/top_level.txt
@@ -0,0 +1 @@
+cvm
diff --git a/docs/upload-to-pypi.md b/docs/upload-to-pypi.md
new file mode 100644
index 0000000..b6b774b
--- /dev/null
+++ b/docs/upload-to-pypi.md
@@ -0,0 +1,34 @@
+# Table of contents
+
+* [Table of contents](#table-of-contents)
+  * [Pre-req](#pre-req)
+  * [Upload process](#upload-process)
+
+## Pre-req
+
+* Register an account with (pypi.org)[https://pypi.org]
+* Register an account with (Test Pypi)[https://test.pypi.org]
+* Install twine with `pip install twine`
+
+## Upload process
+
+* Build your release candidate with:
+
+```bash
+python setup.py sdist bdist_wheel
+```
+
+* Using a test repository
+
+```bash
+twine upload --repository testpypi dist/*
+```
+
+will upload to `https://test.pypi.org/project/<sampleproject>`
+
+* Upload the package with
+
+```bash
+twine check dist/* # Check for errors/warnings
+twine upload dist/*
+```
diff --git a/setup.cfg b/setup.cfg
new file mode 100644
index 0000000..22efb32
--- /dev/null
+++ b/setup.cfg
@@ -0,0 +1,4 @@
+# Inside of setup.cfg
+[metadata]
+description-file = README.md
+
diff --git a/setup.py b/setup.py
index b85166e..b914b4c 100644
--- a/setup.py
+++ b/setup.py
@@ -1,12 +1,23 @@
 from setuptools import setup, find_packages
+import pathlib
+
+
+requirements_data = pathlib.Path('.', 'requirements.txt').read_text().split('\n')
+readme = pathlib.Path('.', 'README.md').read_text()
 
 setup(
-    name='Composer Version Manager',
+    name='composer version manager',
     packages=find_packages(),
+    version='1.0.7',
+    license='MIT',
+    long_description=readme,
+    long_description_content_type="text/markdown",
+    url = 'https://github.com/composer-version-manager/cvm',
     entry_points={
         'console_scripts': [
             'cvm=cvm.cli:main',
         ],
     },
-    python_requires='>=3'
+    install_requires = requirements_data,
+    python_requires='>=3',
 )