feat: tmux and fish config and whatnot
This commit is contained in:
parent
b091a87904
commit
3b0950e88b
|
@ -1,7 +1,12 @@
|
|||
# Make normal mode the default
|
||||
set vi_mode_default vi_mode_normal
|
||||
set fish_cursor_default block # Set the normal and visual mode cursors to a block
|
||||
set fish_cursor_insert line # Set the insert mode cursor to a line
|
||||
set fish_cursor_replace_one underscore # Set the replace mode cursor to an underscore
|
||||
|
||||
function vi_mode_user_key_bindings
|
||||
echo "Added keybinds (hopefully)"
|
||||
bind jj 'commandline -f backward-char; vi_mode_normal'
|
||||
function fish_user_key_bindings
|
||||
# Use the vim keybinds
|
||||
fish_vi_key_bindings
|
||||
|
||||
# Use jj to exit insert mode
|
||||
bind -e -M insert \e # unbinds esc
|
||||
bind -M insert -m default jj 'commandline -f repaint'
|
||||
end
|
||||
|
|
|
@ -3,6 +3,10 @@ set -g prefix C-a
|
|||
unbind C-b
|
||||
bind C-a send-prefix
|
||||
|
||||
# More colors
|
||||
set-option -g default-terminal "tmux-256color"
|
||||
set -g -a terminal-overrides ',*:Ss=\E[%p1%d q:Se=\E[2 q'
|
||||
|
||||
# force a reload of the config file (I don't think this works on nixos)
|
||||
unbind r
|
||||
bind r source-file ~/.tmux.conf
|
||||
|
|
118
flake.lock
118
flake.lock
|
@ -1,21 +1,5 @@
|
|||
{
|
||||
"nodes": {
|
||||
"agnoster": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1641807476,
|
||||
"narHash": "sha256-qi4G08yA21iKsTGR8qBlYp36xflW2UqNYlCjn+vRfLc=",
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "theme-agnoster",
|
||||
"rev": "1ffca413bfbc8941c28982eea97c1e1fa3612d57",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "theme-agnoster",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"easy-dhall-nix": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
@ -48,19 +32,67 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fish-plugin-vi-mode": {
|
||||
"fish-plugin-z": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1613331590,
|
||||
"narHash": "sha256-kRYWbTVT+eV5t5ZvV8abL2zIUnOZMbc2Gk+hDhX6hPM=",
|
||||
"lastModified": 1626157139,
|
||||
"narHash": "sha256-pWkEhjbcxXduyKz1mAFo90IuQdX7R8bLCQgb0R+hXs4=",
|
||||
"owner": "jethrokuan",
|
||||
"repo": "z",
|
||||
"rev": "45a9ff6d0932b0e9835cbeb60b9794ba706eef10",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "jethrokuan",
|
||||
"repo": "z",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fish-theme-agnoster": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1641807476,
|
||||
"narHash": "sha256-qi4G08yA21iKsTGR8qBlYp36xflW2UqNYlCjn+vRfLc=",
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "plugin-vi-mode",
|
||||
"rev": "2655a7253077faefd2f0a57b799dee687344d4fb",
|
||||
"repo": "theme-agnoster",
|
||||
"rev": "1ffca413bfbc8941c28982eea97c1e1fa3612d57",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "plugin-vi-mode",
|
||||
"repo": "theme-agnoster",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fish-theme-dangerous": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1547694252,
|
||||
"narHash": "sha256-OnbS1X/FQaEyVIlgR7YOJlAUu3bgnm2UWk5vm80Cvvc=",
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "theme-dangerous",
|
||||
"rev": "3cdfc82060ba280b44f1f0c6616675f36a275467",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "theme-dangerous",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fish-theme-harleen": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1631660209,
|
||||
"narHash": "sha256-DHGjy7UGzy+vuzHrw49KP0nePKvx7sMMMrPj2mbGoJA=",
|
||||
"owner": "aneveux",
|
||||
"repo": "theme-harleen",
|
||||
"rev": "caf53d792038e78faa7b6b6b98669abc171c5e64",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "aneveux",
|
||||
"repo": "theme-harleen",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
|
@ -272,21 +304,39 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"oh-my-fish": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1646778488,
|
||||
"narHash": "sha256-7mBxP5F81U+V0ahrsXL0vGPivTbKMnqYE5vgG/IOBe8=",
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "oh-my-fish",
|
||||
"rev": "ab05441000531d0bc9aaea23b8d4db59b2828a31",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oh-my-fish",
|
||||
"repo": "oh-my-fish",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"agnoster": "agnoster",
|
||||
"easy-dhall-nix": "easy-dhall-nix",
|
||||
"easy-purescript-nix": "easy-purescript-nix",
|
||||
"fish-plugin-vi-mode": "fish-plugin-vi-mode",
|
||||
"fish-plugin-z": "fish-plugin-z",
|
||||
"fish-theme-agnoster": "fish-theme-agnoster",
|
||||
"fish-theme-dangerous": "fish-theme-dangerous",
|
||||
"fish-theme-harleen": "fish-theme-harleen",
|
||||
"githubNvimTheme": "githubNvimTheme",
|
||||
"home-manager": "home-manager",
|
||||
"neovim-nightly-overlay": "neovim-nightly-overlay",
|
||||
"nixos-unstable": "nixos-unstable",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||
"oh-my-fish": "oh-my-fish",
|
||||
"telescope-file-browser-nvim": "telescope-file-browser-nvim",
|
||||
"vim-extra-plugins": "vim-extra-plugins",
|
||||
"z": "z"
|
||||
"vim-extra-plugins": "vim-extra-plugins"
|
||||
}
|
||||
},
|
||||
"telescope-file-browser-nvim": {
|
||||
|
@ -324,22 +374,6 @@
|
|||
"repo": "nixpkgs-vim-extra-plugins",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"z": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1626157139,
|
||||
"narHash": "sha256-pWkEhjbcxXduyKz1mAFo90IuQdX7R8bLCQgb0R+hXs4=",
|
||||
"owner": "jethrokuan",
|
||||
"repo": "z",
|
||||
"rev": "45a9ff6d0932b0e9835cbeb60b9794ba706eef10",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "jethrokuan",
|
||||
"repo": "z",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
|
|
40
flake.nix
40
flake.nix
|
@ -9,17 +9,27 @@
|
|||
home-manager.url = "github:nix-community/home-manager";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
||||
neovim-nightly-overlay.url = "github:nix-community/neovim-nightly-overlay";
|
||||
neovim-nightly-overlay.inputs.nixpkgs.follows = "nixpkgs";
|
||||
#### Nvim stuff
|
||||
neovim-nightly-overlay = {
|
||||
url = "github:nix-community/neovim-nightly-overlay";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
vim-extra-plugins.url = "github:m15a/nixpkgs-vim-extra-plugins";
|
||||
|
||||
# Git repo fetching
|
||||
# Create / delete files within telescope
|
||||
telescope-file-browser-nvim = {
|
||||
url = "github:nvim-telescope/telescope-file-browser.nvim";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
# Github inspired theme for a bunch of stuff
|
||||
githubNvimTheme = {
|
||||
url = "github:projekt0n/github-nvim-theme";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
#### Purescript stuff
|
||||
easy-dhall-nix = {
|
||||
url = "github:justinwoo/easy-dhall-nix";
|
||||
flake = false;
|
||||
|
@ -30,23 +40,29 @@
|
|||
flake = false;
|
||||
};
|
||||
|
||||
z = {
|
||||
#### Fish stuff
|
||||
fish-plugin-z = {
|
||||
url = "github:jethrokuan/z";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
fish-plugin-vi-mode = {
|
||||
url = "github:oh-my-fish/plugin-vi-mode";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
agnoster = {
|
||||
fish-theme-agnoster = {
|
||||
url = "github:oh-my-fish/theme-agnoster";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
githubNvimTheme = {
|
||||
url = "github:projekt0n/github-nvim-theme";
|
||||
fish-theme-harleen = {
|
||||
url = "github:aneveux/theme-harleen";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
fish-theme-dangerous = {
|
||||
url = "github:oh-my-fish/theme-dangerous";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
oh-my-fish = {
|
||||
url = "github:oh-my-fish/oh-my-fish";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,18 +1,43 @@
|
|||
{ pkgs, ... }:
|
||||
{ lib, pkgs, ... }:
|
||||
let
|
||||
shellAliases = import ./aliases.nix;
|
||||
common = import ./common.nix;
|
||||
|
||||
theme = "dangerous";
|
||||
themePackage = builtins.getAttr theme pkgs.myFishPlugins.themes; # Dynamically pick the theme path
|
||||
in
|
||||
{
|
||||
home-manager.users.adrielus.programs.fish = {
|
||||
inherit shellAliases;
|
||||
home-manager.users.adrielus = {
|
||||
# Source every file in the theme
|
||||
xdg.configFile."fish/conf.d/plugin-${theme}.fish".text = lib.mkAfter ''
|
||||
for f in $plugin_dir/*.fish
|
||||
source $f
|
||||
end
|
||||
'';
|
||||
|
||||
shellInit = ''
|
||||
source ${../../../dotfiles/fish/fish.conf}
|
||||
'' ++ common.shellInit;
|
||||
programs.fish = {
|
||||
inherit shellAliases;
|
||||
|
||||
plugins = with pkgs; [ myFishPlugins.z myFishPlugins.vi-mode myFishPlugins.themes.agnoster ];
|
||||
enable = true;
|
||||
plugins = with pkgs; [
|
||||
myFishPlugins.z # jump around the file system with ease (might replace with autojump)
|
||||
themePackage # theme
|
||||
];
|
||||
|
||||
enable = true;
|
||||
shellInit = ''
|
||||
source ${../../../dotfiles/fish/config.fish}
|
||||
|
||||
# Source the entire oh-my-fish lib
|
||||
for f in ${pkgs.myFishPlugins.oh-my-fish}/lib/git/**/*.fish
|
||||
source $f
|
||||
end
|
||||
|
||||
# if [ "${theme}" = "dangerous" ]
|
||||
set dangerous_colors 000000 333333 666666 ff4ff0 0088ff ff6600 ff0000 ff0033 3300ff 0000ff 00ffff 00ff00
|
||||
# end
|
||||
|
||||
${common.shellInit}
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -5,9 +5,11 @@
|
|||
, nixos-unstable
|
||||
, easy-purescript-nix
|
||||
, easy-dhall-nix
|
||||
, z
|
||||
, fish-plugin-vi-mode
|
||||
, agnoster
|
||||
, fish-plugin-z
|
||||
, fish-theme-harleen
|
||||
, fish-theme-agnoster
|
||||
, fish-theme-dangerous
|
||||
, oh-my-fish
|
||||
, githubNvimTheme
|
||||
, vim-extra-plugins
|
||||
, telescope-file-browser-nvim
|
||||
|
@ -30,25 +32,31 @@ in
|
|||
easy-dhall-nix = self.callPackage easy-dhall-nix { };
|
||||
|
||||
myFishPlugins = {
|
||||
inherit oh-my-fish;
|
||||
|
||||
z = {
|
||||
src = z;
|
||||
src = fish-plugin-z;
|
||||
name = "z";
|
||||
};
|
||||
vi-mode = {
|
||||
src = fish-plugin-vi-mode;
|
||||
name = "vi-mode";
|
||||
};
|
||||
|
||||
themes = {
|
||||
agnoster = {
|
||||
src = agnoster;
|
||||
src = fish-theme-agnoster;
|
||||
name = "agnoster";
|
||||
};
|
||||
|
||||
dangerous = {
|
||||
src = fish-theme-dangerous;
|
||||
name = "dangerous";
|
||||
};
|
||||
|
||||
harleen = {
|
||||
src = fish-theme-harleen;
|
||||
name = "harleen";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
githubNvimTheme = githubNvimTheme;
|
||||
|
||||
# Vim plugins
|
||||
|
|
Loading…
Reference in a new issue