Giter Site home page Giter Site logo

tmux-conda-inherit's Introduction

conda inherit plugin

You are working on a new project, you have your conda environment set up with all your requirements, you are about to test run your changes on a new pane.

Why is my conda environment back to "base"?! 😩

Introducing the conda-inherit plugin for tmux!

You won't be annoyed like that again, your tmux will now always open new windows and panes with the environment of your currently selected (cursor) window/pane.

To install, just follow the instructions below! 😎

Requirements

The following dependencies are required in order to use this plugin:

Installation (via tpm)

Add the following lines to your tmux.config file:

set -g @plugin 'oluevaera/tmux-conda-inherit'

Extend your current new-window and split-window keybinds with -e "TMUX_PARENT_PANE_ID=#{pane_id}.
For example:

bind '%' run 'tmux split-window -c "#{pane_current_path}" -e "TMUX_PARENT_PANE_ID=#{pane_id}" -h'
bind '"' run 'tmux split-window -c "#{pane_current_path}" -e "TMUX_PARENT_PANE_ID=#{pane_id}" -v'
bind c run 'tmux new-window -c "#{pane_current_path}" -e "TMUX_PARENT_PANE_ID=#{pane_id}"'

Add the following lines to your .bashrc or .zshrc.

if [[ -n "$TMUX" ]] then
  export flavor='micromamba'
  source $HOME/.config/tmux/plugins/conda-inherit/conda-inherit.sh
fi

Change the flavor value to the conda version you're using (conda, mamba, micromamba, etc.).
Make sure that the source path corresponds to the conda-inherit plugin path.

Future

Working on adding support for fish.

tmux-conda-inherit's People

Contributors

oluevaera avatar

Stargazers

Tudor avatar Kai Chen avatar Rustam Uzairov avatar Dušan Simić avatar Maximilian Schambach avatar Panagiotis Christopoulos Charitos avatar

Watchers

Maximilian Schambach avatar  avatar

Forkers

ancientjpeg

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.