aaronkjones / noobs-term

A terminal bundle installer

Home Page:https://noobs-term.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

where or how should i add wakatime plugin?

alexzaizar09 opened this issue · comments

This should do it...

  1. clone the zsh-wakatime plugin
    cd ~/.oh-my-zsh/custom/plugins && git clone https://github.com/wbingli/zsh-wakatime.git
  2. then open zshrc
    vim ~/.zshrc
  3. then where you see the plugins section add zsh-wakatime

Like so,

plugins=(
  git # https://github.com/robbyrussell/oh-my-zsh/wiki/Plugin:git
  history-substring-search # ZSH port of Fish history search. Begin typing command, use up arrow to select previous use
  zsh-autosuggestions # Suggests commands based on your history
  zsh-completions # More completions
  zsh-syntax-highlighting # Fish shell like syntax highlighting for Zsh
  colored-man-pages # Self-explanatory
  zsh-wakatime
  )
  1. source zshrc or reload the terminal
    source ~/.zshrc

Great, thank you. Another question, why have i lost the ability to open a terminal from inside a folder. Let me explain, if i use the right click i can see in the menu the "open in terminal" but once the terminal opens it is not pointing to the current directory, why? and how could i change it.

What platform are you on? Windows, Mac, ?

Linux, Ubuntu 18.04

Ok, this is because of tmux.

In ~/.zshrc:

if [ -z "$TMUX" ] # When zsh is started attach to current tmux session or create a new one
then
    tmux attach -t TMUX || tmux new -s TMUX
fi

So, when you launch a terminal or when anything launches a terminal (such as Nautilus with the "open in terminal" option), it will reattach to your tmux session. This is on purpose.

One option would be to remove the code above from ~/.zshrc and then manually reattach to a tmux session when you start a terminal. Which would go something like...

  • open terminal
  • enter tmux attach -t <session name>
  • or, if a session doesn't exist tmux new -s TMUX