A simple and easy to use Python's PIP configuration manager, similar to the Arch Linux's Java manager.

Overview

PIPCONF - The PIP configuration manager

If you need to manage multiple configurations containing indexes and trusted hosts for PIP, this project was made for you.

Introduction

The pipconf is based in pip.conf files in $HOME/.pip folder. But you won't create it with this name. So, you need to create your configuration files following the template config-file-name.conf.

For the first steps, create a $HOME/.pip folder.

# Create the folder, and enter it
$ mkdir $HOME/.pip
$ cd $HOME/.pip

# Create 2 files inside .pip folder
$ touch personal-config.conf company-config.conf

Inside the files, you can put the configurations like index-url, timeout, extra-index-url, trusted-host, etc. You can confer here all the options.

<!-- personal-config.conf -->

[global]
index-url = https://pypi.org/simple/
trusted-host = pypi.org
<!-- company-config.conf -->

[global]
index-url = http://mycompany.com/artifactory/api/pypi/pypi/simple
extra-index-url = http://mycompany.com/artifactory/api/pypi/pypi-local/simple/
trusted-host = mycompany.com

Instalation

The package is available at pypi.org. Then, you can install it using pip.

$ pip install pipconf

If you prefet to install from code, try this. This project uses only pure Python. So, you don't need to install any project dependencies. Just run the setuptools installer.

$ python setup.py install

Usage

$ pipconf --help

The expected output should be something like the following content.

usage: pipconf [-h] [--current] [--list] [--set FILENAME] [--local]

______ ___________  _____ _____ _   _ ______
| ___ \_   _| ___ \/  __ \  _  | \ | ||  ___|
| |_/ / | | | |_/ /| /  \/ | | |  \| || |_
|  __/  | | |  __/ | |   | | | | . ` ||  _|
| |    _| |_| |    | \__/\ \_/ / |\  || |
\_|    \___/\_|     \____/\___/\_| \_/\_|  v0.1.0

Under BSD-2-Clause License, by @jjpaulo2
Contribute at https://github.com/jjpaulo2/pipconf

optional arguments:
-h, --help      show this help message and exit

display informations:
--current       show the current pip configuration file
--list          list all user configurations avaliable at $HOME/.pip

change configuration:
--set FILENAME  set the global configuration for pip from a file in $HOME/.pip
--local         set the pip configuration for the current directory file

Querying the current configuration file

$ pipconf --current

This command will show the current file used. If you are not using anyone, it will show it too.

The current pip configuration file is /home/jjpaulo2/.pip/personal-config.conf

Querying the avaliable configuration files in $HOME/.pip

$ pipconf --list

This command will show the avaliable configuration files in $HOME/.pip folder. If someone of then is being used, you will see a * simbol at it left.

* personal-config (/home/jjpaulo2/.pip/personal-config.conf)
  company-config (/home/jjpaulo2/.pip/company-config.conf)

Setting a file from $HOME/.pip as current configuration file

$ pipconf --set company-config

This will update the current file used, and will output the following message.

Current pip configuration successfully updated.
The active config file is /home/jjpaulo2/.pip/company-config.conf

Setting a pip.conf file from the current working directory

$ ls
pip.conf ...

If the current directory you are in, have a pip.conf file, then you can just active it.

pipconf --local

The output should be something like the following content.

Geting configuration file from current directory.
The active config file is /home/jjpaulo2/dev/myproject/pip.conf
You might also like...
An assistant to guess your pip dependencies from your code, without using a requirements file.

Pip Sala Bim is an assistant to guess your pip dependencies from your code, without using a requirements file. Pip Sala Bim will tell you which packag

InverterApi - This project has been designed to take monitoring data from Voltronic, Axpert, Mppsolar PIP, Voltacon, Effekta

InverterApi - This project has been designed to take monitoring data from Voltronic, Axpert, Mppsolar PIP, Voltacon, Effekta

Py4J enables Python programs to dynamically access arbitrary Java objects

Py4J Py4J enables Python programs running in a Python interpreter to dynamically access Java objects in a Java Virtual Machine. Methods are called as

Todos os exercícios do Curso de Python, do canal Curso em Vídeo, resolvidos em Python, Javascript, Java, C++, C# e mais...
Todos os exercícios do Curso de Python, do canal Curso em Vídeo, resolvidos em Python, Javascript, Java, C++, C# e mais...

Exercícios - CeV Oferecido por Linguagens utilizadas atualmente O que vai encontrar aqui? 👀 Esse repositório é dedicado a armazenar todos os enunciad

Tools for analyzing Java JVM gc log files

gc_log This package consists of two separate utilities useful for : gc_log_visualizer.py regionsize.py GC Log Visualizer This was updated to run under

Check broken access control exists in the Java web application
Check broken access control exists in the Java web application

javaEeAccessControlCheck Check broken access control exists in the Java web application. 检查 Java Web 应用程序中是否存在访问控制绕过问题。 使用 python3 javaEeAccessControl

🎉 🎉 PyComp - Java Code compiler written in python.

🎉 🎉 PyComp Java Code compiler written in python. This is yet another compiler meant for babcock students project which was created using pure python

PyGo custom language, New but similar language programming

New but similar language programming. Now we are capable to program in a very similar language to Python but at the same time get the efficiency of Go.

Jogo em redes similar ao clássico pedra papel e tesoura

Batalha Tática Tecnologias de Redes de Computadores-A-N-JOGOS DIGITAIS Professor Fabio Henrique Cabrini Alunos: Eric Henrique de Oliveira Silva - RA 1

Comments
  • Comando para criar nova configuração

    Comando para criar nova configuração

    Podemos adicionar um novo comando à ferramenta, como por exemplo, pipconf new <config-name> para que seja criado um novo arquivo de configurações, e abrindo ele em algum editor de texto padrão para edição.

    opened by jjpaulo2 0
  • Criar arquivo pip.conf automaticamente na primeira execução

    Criar arquivo pip.conf automaticamente na primeira execução

    Hoje, é necessário primeiro configurar manualmente a pasta $HOME/.pip e povoar ela com ao menos um arquivo para tornar possível iniciar a utilizar a ferramenta.

    Seria ideal que caso a pasta $HOME/.pip não exista ou não haja nenhuma arquivo de configuração nela, isso seja gerado automaticamente na primeira vez em que a ferramenta é executada.

    opened by jjpaulo2 0
Releases(1.0.0)
Owner
João Paulo Carvalho
Back End Engineer at Serasa eCred. Python lover. Game development enthusiast.
João Paulo Carvalho
PREFS is a Python library to store and manage preferences and settings.

PREFS PREFS is a Python library to store and manage preferences and settings. PREFS stores a Python dictionary in a total human-readable file, the PRE

Pat 13 May 26, 2022
dynamically create __slots__ objects with less code

slots_factory Factory functions and decorators for creating slot objects Slots are a python construct that allows users to create an object that doesn

Michael Green 2 Sep 07, 2021
TallerStereoVision Convencion Python Chile 2021

TallerStereoVision Convencion Python Chile 2021 Taller Stereo Vision & Python PyCon.cl 2021 Instalación Se recomienta utilizar Virtual Environment pyt

2 Oct 20, 2022
En este repositorio realizaré la tarea del laberinto.

Laberinto Perfil de GitHub del autor de este proyecto: @jmedina28 En este repositorio queda resuelta la composición de un laberinto 5x5 con sus muros

Juan Medina 1 Dec 11, 2021
The most widely used Python to C compiler

Welcome to Cython! Cython is a language that makes writing C extensions for Python as easy as Python itself. Cython is based on Pyrex, but supports mo

7.6k Jan 03, 2023
We want to check several batch of web URLs (1~100 K) and find the phishing website/URL among them.

We want to check several batch of web URLs (1~100 K) and find the phishing website/URL among them. This module is designed to do the URL/web attestation by using the API from NUS-Phishperida-Project.

3 Dec 28, 2022
一个Graia-Saya的插件仓库

一个Graia-Saya的插件仓库 这是一个存储基于 Graia-Saya 的插件的仓库 如果您有这类项目

ZAPHAKIEL 111 Oct 24, 2022
Contains a Jupyter Notebook for calculating remaining plants required based on field/lathhouse data.

Davis-Sunflowers-Su21 Project goals: Plants influence their reproduction and mating system in many ways. Various factors such as time of flowering, ab

1 Feb 10, 2022
Scraper pour les offres de stage Tesla et les notes sur Oasis (Polytech Paris-Saclay) sous forme de bot Discord

Scraper pour les offres de stage Tesla et les notes sur Oasis (Polytech Paris-Saclay) sous forme de bot Discord

Alexandre Malfreyt 1 Jan 21, 2022
A Linux program to create a Windows USB stick installer from a real Windows DVD or image.

WoeUSB-ng A Linux program to create a Windows USB stick installer from a real Windows DVD or image. This package contains two programs: woeusb: A comm

Longinus 1 Nov 19, 2021
Really bad lisp implementation. Fun with pattern matching.

Lisp-py This is a horrible, ugly interpreter for a trivial lisp. Don't use it. It was written as an excuse to mess around with the new pattern matchin

Erik Derohanian 1 Nov 23, 2021
Supercharge your NFTs with new behaviours and superpowers!

WrapX Supercharge your NFTs with new behaviours and superpowers! WrapX is a collection of Wrappers (currently one - WrapXSet) to decorate your NTFs ad

Emiliano Bonassi 9 Jun 13, 2022
Compress .dds file in ggpk to boost fps. This is a python rewrite of PoeTexureResizer.

PoeBooster Compress .dds file in ggpk to boost fps. This is a python rewrite of PoeTexureResizer. Setup Install ImageMagick-7.1.0. Download and unzip

3 Sep 30, 2022
Standard mutable string (character array) implementation for Python.

chararray A standard mutable character array implementation for Python.

Tushar Sadhwani 3 Dec 18, 2021
Collie is for uncovering RDMA NIC performance anomalies

Collie is for uncovering RDMA NIC performance anomalies. Overview Prerequ

Bytedance Inc. 34 Dec 11, 2022
Implements a polyglot REPL which supports multiple languages and shared meta-object protocol scope between REPLs.

MetaCall Polyglot REPL Description This repository implements a Polyglot REPL which shares the state of the meta-object protocol between the REPLs. Us

MetaCall 10 Dec 28, 2022
Sigma coding youtube - This is a collection of all the code that can be found on my YouTube channel Sigma Coding.

Sigma Coding Tutorials & Resources YouTube • Facebook Support Sigma Coding Patreon • GitHub Sponsor • Shop Amazon Table of Contents Overview Topics Re

Alex Reed 927 Jan 08, 2023
Render reMarkable documents to PDF

rmrl: reMarkable Rendering Library rmrl is a Python library for rendering reMarkable documents to PDF files. It takes the original PDF document and th

Robert Schroll 95 Dec 25, 2022
Request ID propagation for ASGI apps

ASGI Correlation ID middleware Middleware for loading and receiving correlation IDs from request HTTP headers, and making them available in applicatio

snok 170 Jan 02, 2023
Python package for reference counting native pointers

refcount master: testing: This package is primarily for managing resources in native libraries, written for instance in C++, from Python. While it boi

CSIRO Hydroinformatics 2 Nov 03, 2022