Skip to content

Commit

Permalink
home-manager/jetbrains: init
Browse files Browse the repository at this point in the history
  • Loading branch information
thiagokokada committed Dec 11, 2023
1 parent 2259df7 commit c8ecc80
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 4 deletions.
17 changes: 17 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 13 additions & 4 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@
flake = false;
};

# IntelliJ
intellimacs = {
url = "github:MarcoIeni/intellimacs";
flake = false;
};

# custom packages
arandr = {
url = "gitlab:thiagokokada/arandr";
Expand Down Expand Up @@ -154,10 +160,13 @@
system = "aarch64-darwin";
homePath = "/Users";
extraModules = [{
home-manager.dev = {
clojure.enable = false;
go.enable = false;
node.enable = false;
home-manager = {
editor.jetbrains.enable = true;
dev = {
clojure.enable = false;
go.enable = false;
node.enable = false;
};
};
}];
})
Expand Down
1 change: 1 addition & 0 deletions home-manager/editor/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
imports = [
./emacs
./helix.nix
./jetbrains.nix
./neovim.nix
./vscode
];
Expand Down
38 changes: 38 additions & 0 deletions home-manager/editor/jetbrains.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{ config, lib, pkgs, flake, ... }:

{
# TODO: add declarative IDE setup
# https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/editors/jetbrains/readme.md
options.home-manager.editor.jetbrains.enable = lib.mkDefaultOption "Jetbrains IDEs config";

config = lib.mkIf config.home-manager.editor.jetbrains.enable {
home.file = {
".intellimacs".source = flake.inputs.intellimacs;
".ideavimrc".source = pkgs.writeText "ideavimrc" /* vim */ ''
source ~/.intellimacs/spacemacs.vim
" Enable other Intellimacs modules
source ~/.intellimacs/extra.vim
source ~/.intellimacs/major.vim
source ~/.intellimacs/hybrid.vim
" Enable which-key plugin
source ~/.intellimacs/which-key.vim
" Comma for major mode
nmap , <leader>m
vmap , <leader>m
" Plugins
Plug 'easymotion/vim-easymotion'
Plug 'preservim/nerdtree'
Plug 'tpope/vim-surround'
Plug 'tpope/vim-commentary'
Plug 'michaeljsmith/vim-indent-object'
" Vinegar
nmap - :NERDTreeToggle<CR>
'';
};
};
}

0 comments on commit c8ecc80

Please sign in to comment.