forked from vIadmeer/polymarket-bot
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
61 lines (57 loc) · 7.09 KB
/
setup.py
File metadata and controls
61 lines (57 loc) · 7.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
import os
import sys
from setuptools import setup, find_packages
from fnmatch import fnmatchcase
from distutils.util import convert_path
standard_exclude = ('*.pyc', '*~', '.*', '*.bak', '*.swp*')
standard_exclude_directories = ('.*', 'CVS', '_darcs', './build', './dist', 'EGG-INFO', '*.egg-info')
def find_package_data(where='.', package='', exclude=standard_exclude, exclude_directories=standard_exclude_directories):
out = {}
stack = [(convert_path(where), '', package)]
while stack:
where, prefix, package = stack.pop(0)
for name in os.listdir(where):
fn = os.path.join(where, name)
if os.path.isdir(fn):
bad_name = False
for pattern in exclude_directories:
if (fnmatchcase(name, pattern)
or fn.lower() == pattern.lower()):
bad_name = True
break
if bad_name:
continue
if os.path.isfile(os.path.join(fn, '__init__.py')):
if not package:
new_package = name
else:
new_package = package + '.' + name
stack.append((fn, '', new_package))
else:
stack.append((fn, prefix + name + '/', package))
else:
bad_name = False
for pattern in exclude:
if (fnmatchcase(name, pattern)
or fn.lower() == pattern.lower()):
bad_name = True
break
if bad_name:
continue
out.setdefault(package, []).append(prefix+name)
return out
setup(name='docassemble.ALDashboard',
version='0.22.0',
description=('Dashboard for some admin tasks'),
long_description='# ALDashboard: a docassemble Admin and Configuration Tool\r\n\r\n[](https://badge.fury.io/py/docassemble.ALDashboard)\r\n\r\nA single tool and interview to centralizes some tedious Docassemble admin configuration tasks\r\n\r\n\r\n\r\n1. Install the Document Assembly Line packages (support files for [Court Forms Online](https://courtformsonline.org))\r\n1. Searchable user management - reset passwords and change privileges.\r\n1. Installing or updating several packages at once.\r\n1. Listing and viewing the contents of an (unencrypted) interview to facilitate debugging errors on production servers.\r\n1. View analytics/stats captured with `store_variable_snapshot`.\r\n1. List the files inside a particular package installed on the server.\r\n1. Gather files from a user who left the organization/unknown username and password.\r\n1. Review screen generator\r\n1. validate DOCX Jinja2 templates\r\n1. Generating a [custom bootstrap theme](https://suffolklitlab.org/docassemble-AssemblyLine-documentation/docs/customization/overview#creating-a-custom-theme-from-source-instead-of-with-a-theme-generator) for your interviews.\r\n\r\nIdeas:\r\n1. Add a link to the dispatch directive for an existing file in an existing package.\r\n1. Generating translation files [TBD].\r\n\r\nTo use, you must create a docassemble API key and add it to your\r\nconfiguration, like this:\r\n\r\n`install packages api key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx`\r\n\r\n## Some screenshots\r\n\r\n### Main page\r\n\r\n\r\n### Manage users\r\n\r\n\r\n\r\n### Bulk install packages from GitHub\r\n\r\n\r\n\r\n### Bulk update packages\r\n\r\n\r\n\r\n### View / search sessions by user and interview name\r\n\r\n\r\n\r\n\r\n\r\n### View interview stats captured with `store_variables_snapshot()`\r\n\r\n\r\n\r\n### Generate a bootstrap theme\r\n\r\n\r\n',
long_description_content_type='text/markdown',
author='Quinten Steenhuis',
author_email='qsteenhuis@gmail.com',
license='The MIT License (MIT)',
url='https://github.com/SuffolkLITLab/docassemble-ALDashboard',
packages=find_packages(),
namespace_packages=['docassemble'],
install_requires=['PyGithub>=2.1.1', 'docassemble.ALToolbox>=0.9.2', 'openai>=1.0', 'tiktoken'],
zip_safe=False,
package_data=find_package_data(where='docassemble/ALDashboard/', package='docassemble.ALDashboard'),
)