Skip to main content

No project description provided

Project description

NVEXPO - Non-Volatile EXPOrt

nxexpo it's a simple tool to define environment variables on-the-fly and persisting them between shell sessions.

Dependencies

  • Python 3.10

Dependencies to build

Dependencies to develop

Installation

Installation trough PyPI

To install the latest stable version follow the commands:

$ pip install nvexpo --user

You can also use pipx to install it:

$ pipx install nvexpo

From the source

To install from the source follow the commands:

$ poetry build
$ pip install dist/nvexpo*.whl

Preparation

Bash

Add the following line to your .bashrc file:

eval "$(nvexpo init bash)"

ZSH

Add the following line to your .zshrc file:

eval "$(nvexpo init zsh)"

Fish

Add the following line to your config.fish file:

nvexpo init fish | source

Basic usage

The usage it's too simple. If you want to create a new env var into the current bash session use the command:

$ nx weird_variable=101

Then, you can close the current terminal or terminate the bash session, and when you start a new one, your env vars will still be there :sparkles:.

$ echo $weird_variable
101

Unset variables

To unset variables you need to use flag --unset:

$ nx var1="hello world"
$ echo $var1
hello world
$ nx --unset var1
$ echo $var1

$ works!!

Why?

The main motivation for creating this tool was that in my work I like to have the Git branch I'm working on in $branch, but it's annoying to have to create it every time I restart or close the terminal I was working on. I could add it to .bashrc directly, but I would have to do it every time I have to work on a new branch and it wasn't comfortable. So now instead of having to type:

branch="super_useful_change"

I have to write:

nx branch="super_useful_change"

and that's it, no matter how many times I restart, my variable will be there.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nvexpo-0.1.5.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nvexpo-0.1.5-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file nvexpo-0.1.5.tar.gz.

File metadata

  • Download URL: nvexpo-0.1.5.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.0 CPython/3.13.13 Linux/7.0.10-2-default

File hashes

Hashes for nvexpo-0.1.5.tar.gz
Algorithm Hash digest
SHA256 2c6b86ebbf2ab650d3801f7da2f41485a967a29f5c64a3d6d5704927e35699b5
MD5 9451bf9b5e2e6ce3d960dbe674dfc3ea
BLAKE2b-256 890f37b656168fda2f193a36187f8f7dba1c44120e6ed1dec5fc901d327da149

See more details on using hashes here.

File details

Details for the file nvexpo-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: nvexpo-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.0 CPython/3.13.13 Linux/7.0.10-2-default

File hashes

Hashes for nvexpo-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 d538e8239091b50be7154a6fc0d5aa36d5b65329be8161215714a1c6012462d9
MD5 d5e04dec658deab8b85954d4aa7638f4
BLAKE2b-256 01174d7818eb3e4f2788bd8d0e77b5ae6ecbee34a5d48dfd25a8f61b2a868969

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page