A drop-in replacement for argparse that allows options to also be set via config files and/or environment variables

Overview Applications with more than a handful of user-settable options are best configured through a combination of command line args, config files, hard-coded defaults, and in some cases, environment variables. Python’s command line parsing modules such as argparse have very limited support for config files and environment variables, so this module extends argparse to add these features. Available on PyPI: http://pypi.python.org/pypi/ConfigArgParse Features command-line, config file, env var, and default settings can now be defined, documented, and parsed in one go […]

Read more

A thin, practical wrapper around terminal capabilities in Python

Coding with Blessings looks like this… from blessings import Terminal t = Terminal() print(t.bold(‘Hi there!’)) print(t.bold_red_on_bright_green(‘It hurts my eyes!’)) with t.location(0, t.height – 1): print(‘This is at the bottom.’) Or, for byte-level control, you can drop down and play with raw terminal capabilities: print(‘{t.bold}All your {t.red}bold and red base{t.normal}’.format(t=t)) print(t.wingo(2)) Full API Reference The Pitch Blessings lifts several of curses‘ limiting assumptions, and it makes your code pretty, too: Use styles, color, and maybe a    

Read more

A python package to help people create full-screen text UIs on any platform

ASCIIMATICS Asciimatics is a package to help people create full-screen text UIs (from interactive forms to ASCII animations) on any platform. It is licensed under the Apache Software Foundation License 2.0. Why? Why not? It brings a little joy to anyone who was programming in the 80s… Oh and it provides a single cross-platform Python class to do all the low-level console function you could ask for, including: Coloured/styled    

Read more

Create beautiful and testable command-line interfaces

Create beautiful and testable command-line interfaces. Cleo is mostly a higher level wrapper for CliKit, so a lot of the components and utilities comes from it. Refer to its documentation for more information. Resources Usage To make a command that greets you from the command line, create greet_command.py and add the following to it: from cleo import Command class GreetCommand(Command): “”” Greets someone greet {name? : Who do you want to greet?} {–y|yell : If set, the task will yell […]

Read more

Boto3 : The AWS SDK for Python

Boto3 is the Amazon Web Services (AWS) Software Development Kit (SDK) for Python, which allows Python developers to write software that makes use of services like Amazon S3 and Amazon EC2. You can find the latest, most up to date, documentation at our doc site, including a list of services that are supported. Getting Started Assuming that you have Python and virtualenv installed, set up your environment and install the required dependencies like this or you can install the library […]

Read more

Typer, build great CLIs. Easy to code. Based on Python type hints

Typer, build great CLIs. Easy to code. Based on Python type hints. Documentation: https://typer.tiangolo.com Source Code: https://github.com/tiangolo/typer Typer is a library for building CLI applications that users will love using and developers will love creating. Based on Python 3.6+ type hints. The key features are: Intuitive to write: Great editor support. Completion everywhere. Less time debugging. Designed to be easy to use and learn. Less time reading docs. Easy to use: It’s easy to use for the final users. Automatic […]

Read more

Google Cloud Client Library for Python

Python idiomatic clients for Google Cloud Platform services. Stability levels The development status classifier on PyPI indicates the current stability of a package. General Availability GA (general availability) indicates that the client library for a particular service is stable, and that the code surface will not change in backwards-incompatible ways unless either absolutely necessary (e.g. because of critical security issues) or with an extensive deprecation period. Issues and requests against GA libraries are addressed with the highest priority. GA libraries […]

Read more

The Python SQL Toolkit and Object Relational Mapper

The Python SQL Toolkit and Object Relational Mapper Introduction SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that gives application developers the full power and flexibility of SQL. SQLAlchemy provides a full suite of well known enterprise-level persistence patterns, designed for efficient and high-performing database access, adapted into a simple and Pythonic domain language. Major SQLAlchemy features include: An industrial strength ORM, built from the core on the identity map, unit of work, and data mapper patterns. These […]

Read more

JustCTF [*] 2020 challenges sources

This repo contains sources for justCTF [*] 2020 challenges hosted by justCatTheFish. TLDR: Run a challenge with ./run.sh (requires Docker/docker-compose and might require sudo as we use nsjail extensively under the hood). The challenges/ contains challanges directories with the following structure: README.md – official challenge description used during CTF run.sh – shell script to run the challenge locally (uses Docker and sometimes docker-compose) public/ – files that were public/to download private/ – sources and other unlisted files flag.txt/metadata.json – the […]

Read more

Cython, Rust, and more: choosing a language for Python extensions

Sometimes pure Python code isn’t enough, and you need to implement an extension in a compiled language like C, C++, or Rust. Maybe your code is slow, and you need to speed it up. Maybe you just need access to a library written in another language. Depending on your particular situation and needs, you may want to choose a different tool. But which one? Let’s see what your options are, and then go through a variety of scenarios and see […]

Read more
1 372 373 374 375 376 928