GithubHelp home page GithubHelp logo

foozzi / cilantropy Goto Github PK

View Code? Open in Web Editor NEW
50.0 6.0 4.0 329 KB

:four_leaf_clover: Cilantropy is a Python Package Manager interface created to provide an "easy-to-use" visual and also a command-line interface for Pythonistas. Works great on windows, linux, macos :star:

License: Other

Python 53.08% JavaScript 2.46% CSS 2.88% HTML 41.17% Dockerfile 0.42%
package-manager distribution-tool cilantropy pypi pip setuptools python3 linux macos windows

cilantropy's Introduction

Cilantropy

Build Status Build Status Downloads License Version Pypi Code style: black Size repo

Cilantropy is a Python Package Manager interface created to provide an "easy-to-use" visual and also a command-line interface for Pythonistas. Today we have many nice distribution utilities like pip, distribute, etc, but we don't have a nice visual approach to inspect current installed packages, show projects metadata, check for PyPI updates, etc.

Demo

Demo Cilantropy

Screenshots

Screenshot: The home

The home

Screenshot: Installed package information

Installed package information

Screenshot: Check PyPI for updates available

Updates

Updates

Updates

'plp' (Python List Packages) console utility

asciicast

How to Install

Installing using pip:

$ pip install cilantropy

Upgrading using pip:

$ pip install --upgrade cilantropy

Docker

Repository @ DockerHub

Docker Compose excerpt

# Docker Compose excerpt
services:
  nginx-ui:
    image: fz11/cilantropy:latest
    ports:
      - 8080:8080
    volumes:
      - nginx:/etc/nginx

uWSGI

uwsgi --http 0.0.0.0:5000 --wsgi-file wsgi.py --callable app --processes 1 --threads 8

Installing as a systemd service

If you're running Linux with systemd (before edit path and other configs in contrib/systemd/cilantropy.service) installed, you can register Cilantropy as a service by copying cilantropy.service (both in contrib/systemd) to /etc/systemd/system.

All standard systemd service management commands (e.g. systemctl enable and systemctl start) apply.

uWSGI + Nginx

Manual

Service management

$ sudo start cilantropy
$ sudo stop cilantropy
$ sudo status cilantropy

or

$ sudo service cilantropy start
$ sudo service cilantropy stop
$ sudo service cilantropy status

Android (Termux)

You can use Cilantropy on your android device with Termux:

$ pkg upgrade
$ pkg install python
$ pip install cilantropy

Authentication

BasicAuth with nginx

In general, this app does not come with authentication. However, it is easy to setup basic auth to restrict unwanted access. Here is how this can be done when using nginx.

Configure the auth file

  1. Verify that apache2-utils (Debian, Ubuntu) or httpd-tools (RHEL/CentOS/Oracle Linux) is installed
  2. Run the htpasswd utility to create a new user and set a passwort.
    • Make sure, that the directory exists
    • Remove the -c flag, if you have created a user before, since it creates the inital user/passwort file
    • sudo htpasswd -c /etc/apache2/.htpasswd user1

Using Cilantropy

You only need to call the script (the -w option will automatically open your browser):

$ cilantropy -w

Using plp

$ plp --help
Cilantropy - Python List Packages (PLP)

Usage:
  plp list [--compact] [<filter>]
  plp show <project_name>
  plp check <project_name>
  plp scripts [<filter>]
  plp paste [list your packages to pastebin service]

  plp (-h | --help)
  plp --version

Options:
  --compact     Compact list format
  -h --help     Show this screen.
  --version     Show version.

Setting a development environment


Developers can setup a development environment using the "develop" command from setuptools:

$ git clone [email protected]:foozzi/cilantropy.git && cd cilantropy
$ pip install flit --user
$ flit install
$ cilantropy

Requirements

Cilantropy uses the following external projects:

Flask

A microframework based on Werkzeug, Jinja2 and good intentions

Bootstrap 4

HTML, CSS, and JS toolkit from Bootstrap

Jinja2 (Flask requirement)

The Jinja2 template engine

Werkzeug (Flask requirement)

A flexible WSGI implementation and toolkit

docopt (used by plp)

Command-line interface description language

colorama (used by plp)

Cross-platform colored terminal text.

docutils

Docutils is an open-source text processing system for processing plaintext documentation into useful formats, such as HTML or LaTeX.

flit (for build and install package)

Flit is a simple way to put Python packages and modules on PyPI.

Compatibility

Cilantropy is compatible with:

  • Python 3

Supported browsers

Cilantropy is compatible with:

  • Firefox
  • Google Chrome
  • Internet Explorer 9/10
  • Safari

Reporting bug

Open an issue in Github with the traceback. To get the traceback, you'll have to run Cilantropy in debugging mode:

$ cilantropy -drvi

License

Copyright (c) 2020, Tkachenko Igor All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1) Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2) Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

3) All advertising materials mentioning features or use of this software must display the following acknowledgement:

"This product includes software developed by the University of California, Berkeley and its contributors."

4) Neither the name of the foozzi nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 

Contributors

See the Contributors.

Links

Project Site - Github

cilantropy's People

Contributors

andydecleyre avatar dependabot[bot] avatar foozzi avatar imgbotapp avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

cilantropy's Issues

pip installation failure in venv: "requires Python 3 or greater"

Arch Linux

$ pacman -Q python{,2,-pip}
python 3.8.3-1
error: package 'python2' was not found
python-pip 20.1.1-1
$ python -m venv venv
$ . ./venv/bin/activate
$ pip --version
pip 19.2.3 from /home/andy/Code/cilantropytest/venv/lib/python3.8/site-packages/pip (python 3.8)
$ pip install cilantropy
Collecting cilantropy
  Using cached https://files.pythonhosted.org/packages/4a/2e/477837ec56e8cba642c19ee122a6843d4a7c9d6dce1fa1a9d69fbfad8727/Cilantropy-0.2.tar.gz
    ERROR: Command errored out with exit status 1:
     command: /home/andy/Code/cilantropytest/venv/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-fd1ehplq/cilantropy/setup.py'"'"'; __file__='"'"'/tmp/pip-install-fd1ehplq/cilantropy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base pip-egg-info
         cwd: /tmp/pip-install-fd1ehplq/cilantropy/
    Complete output (1 lines):
    error: cilantropy requires Python 3 or greater.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
WARNING: You are using pip version 19.2.3, however version 20.1.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
$ pip install -U pip
Collecting pip
  Using cached https://files.pythonhosted.org/packages/43/84/23ed6a1796480a6f1a2d38f2802901d078266bda38388954d01d3f2e821d/pip-20.1.1-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 19.2.3
    Uninstalling pip-19.2.3:
      Successfully uninstalled pip-19.2.3
Successfully installed pip-20.1.1
$ pip install cilantropy
Collecting cilantropy
  Using cached Cilantropy-0.2.tar.gz (123 kB)
    ERROR: Command errored out with exit status 1:
     command: /home/andy/Code/cilantropytest/venv/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-sovf689m/cilantropy/setup.py'"'"'; __file__='"'"'/tmp/pip-install-sovf689m/cilantropy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-f4fsdrfm
         cwd: /tmp/pip-install-sovf689m/cilantropy/
    Complete output (1 lines):
    error: cilantropy requires Python 3 or greater.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
$ pip --no-cache-dir install cilantropy
Collecting cilantropy
  Downloading Cilantropy-0.2.tar.gz (123 kB)
     |████████████████████████████████| 123 kB 3.3 MB/s
    ERROR: Command errored out with exit status 1:
     command: /home/andy/Code/cilantropytest/venv/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-2y17vvdr/cilantropy/setup.py'"'"'; __file__='"'"'/tmp/pip-install-2y17vvdr/cilantropy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-2r_5k9i0
         cwd: /tmp/pip-install-2y17vvdr/cilantropy/
    Complete output (1 lines):
    error: cilantropy requires Python 3 or greater.
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.