diff --git a/README.md b/README.md
index cce2e95..3e216d0 100644
--- a/README.md
+++ b/README.md
@@ -22,18 +22,18 @@
* Download and install last version of **Django Admin Two-Factor Authentication**:
```bash
-$ pip install git+https://github.com/imankarimi/django-admin-two-factor-auth.git
-$ # or
-$ easy_install git+https://github.com/imankarimi/django-admin-two-factor-auth.git
+$ pip install django-admin-two-factor
+# or
+$ easy_install django-admin-two-factor
```
* Add 'admin_two_factor' application to the INSTALLED_APPS setting of your Django project `settings.py` file (note it should be before 'django.contrib.admin'):
```python
INSTALLED_APPS = (
- 'admin_two_factor.apps.TwoStepVerificationConfig',
- 'django.contrib.admin',
- # ...
+'admin_two_factor.apps.TwoStepVerificationConfig',
+'django.contrib.admin',
+# ...
)
```
@@ -55,9 +55,9 @@ ADMIN_TWO_FACTOR_NAME = 'PROJECT_NAME'
```python
urlpatterns = [
- path('admin/', admin.site.urls),
- path('two_factor/', include(('admin_two_factor.urls', 'admin_two_factor'), namespace='two_factor')),
- # ...
+path('admin/', admin.site.urls),
+path('two_factor/', include(('admin_two_factor.urls', 'admin_two_factor'), namespace='two_factor')),
+# ...
]
```
@@ -94,20 +94,24 @@ $ python manage.py runserver # default port 8000
* **User List:** the users who have enabled two-factor auth
+
![Django Admin Two-Factor Auth: User List](https://raw.githubusercontent.com/imankarimi/django-admin-two-factor-auth/main/screenshoots/django_admin_two_factor_auth_4.png)
* **Add New User:**
+
![Django Admin Two-Factor Auth: Add New User](https://raw.githubusercontent.com/imankarimi/django-admin-two-factor-auth/main/screenshoots/django_admin_two_factor_auth_2.png)
* **Scan QRCode and enter the valid code:**
+
![Django Admin Two-Factor Auth: Scan QRCode](https://raw.githubusercontent.com/imankarimi/django-admin-two-factor-auth/main/screenshoots/django_admin_two_factor_auth_3.png)
* **Logout and login again with [Google Authenticator](https://support.google.com/accounts/answer/1066447?hl=en):**
+
![Django Admin Two-Factor Auth: Login with Code](https://raw.githubusercontent.com/imankarimi/django-admin-two-factor-auth/main/screenshoots/django_admin_two_factor_auth_5.png)
diff --git a/setup.cfg b/setup.cfg
deleted file mode 100644
index 20b219a..0000000
--- a/setup.cfg
+++ /dev/null
@@ -1,32 +0,0 @@
-[metadata]
-name = django-admin-two-factor
-version = 0.1
-description = Django Admin Two Factor Authentication.
-long_description = file: README.md
-url = https://github.com/imankarimi/django-admin-two-factor-auth
-author = Iman Karimi
-author_email = imankarimi.mail@gmail.com
-license = MIT
-classifiers =
- Environment :: Web Environment
- Framework :: Django
- Framework :: Django :: 2.*
- Framework :: Django :: 3.1.1
- Intended Audience :: Developers
- License :: OSI Approved :: MIT License
- Operating System :: OS Independent
- Programming Language :: Python
- Programming Language :: Python :: 2.6
- Programming Language :: Python :: 2.7
- Programming Language :: Python :: 3.2
- Programming Language :: Python :: 3.3
- Programming Language :: Python :: 3.4
- Programming Language :: Python :: 3.5
- Programming Language :: Python :: 3.6
- Environment :: Web Environment
- Topic :: Software Development
- Topic :: System :: Systems Administration :: Authentication/Directory
-
-[options]
-include_package_data = true
-packages = find:
\ No newline at end of file
diff --git a/setup.py b/setup.py
index da61e06..1b1bc58 100644
--- a/setup.py
+++ b/setup.py
@@ -1,13 +1,49 @@
-from setuptools import setup, find_packages
+import os
+
+from setuptools import find_packages, setup
+
+with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme:
+ README = readme.read()
+
+os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
+ name='django-admin-two-factor',
+ version='0.0.1',
+ zip_safe=False,
packages=find_packages(),
+ include_package_data=True,
+ description='Django Admin Two Factor Authentication',
+ long_description=README,
+ long_description_content_type="text/markdown",
+ url='https://github.com/imankarimi/django-admin-two-factor-auth',
+ author='Iman Karimi',
+ author_email='imankarimi.mail@gmail.com',
+ license='MIT License',
+ classifiers=[
+ 'Environment :: Web Environment',
+ 'Framework :: Django',
+ 'Framework :: Django :: 2.0',
+ 'Framework :: Django :: 3.2',
+ 'Intended Audience :: Developers',
+ 'License :: OSI Approved :: MIT License',
+ 'Programming Language :: Python',
+ 'Programming Language :: Python :: 2.6',
+ 'Programming Language :: Python :: 2.7',
+ 'Programming Language :: Python :: 3.2',
+ 'Programming Language :: Python :: 3.3',
+ 'Programming Language :: Python :: 3.4',
+ 'Programming Language :: Python :: 3.5',
+ 'Programming Language :: Python :: 3.6',
+ 'Programming Language :: Python :: 3.7',
+ 'Programming Language :: Python :: 3.8',
+ 'Environment :: Web Environment',
+ 'Topic :: Software Development',
+ ],
install_requires=[
'Django',
'pyotp',
'qrcode',
'Pillow',
],
- include_package_data=True,
- zip_safe=False
-)
\ No newline at end of file
+)