Did a bunch of things, most of them having to do with neovim

This commit is contained in:
vorboyvo 2024-02-02 17:09:48 -05:00
parent 8898a6cc13
commit 0c602619b1
7 changed files with 102 additions and 17 deletions

View file

@ -13,6 +13,11 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
# nixvim = {
# url = "github:nix-community/nixvim";
# inputs.nixpkgs.follows = "nixpkgs";
# };
# nur.url = "github:nix-community/NUR"; # nur.url = "github:nix-community/NUR";
}; };
outputs = { self, nixpkgs, home-manager }: outputs = { self, nixpkgs, home-manager }:

View file

@ -18,6 +18,7 @@ in
# Install packages # Install packages
home.packages = with pkgs; home.packages = with pkgs;
[ gcc tree-sitter ] ++ # Basic dev tools
[ texliveFull ] ++ # TeX distribution [ texliveFull ] ++ # TeX distribution
(with ocamlPackages; [ ocaml opam dune_3 dune-release merlin ocaml-lsp odoc ocamlformat utop ]) ++ # OCaml (with ocamlPackages; [ ocaml opam dune_3 dune-release merlin ocaml-lsp odoc ocamlformat utop ]) ++ # OCaml
[ grim slurp wl-clipboard jq (callPackage ./pkgs/xdg-terminal-exec/xdg-terminal-exec.nix {}) ] ++ # Basic utilities [ grim slurp wl-clipboard jq (callPackage ./pkgs/xdg-terminal-exec/xdg-terminal-exec.nix {}) ] ++ # Basic utilities
@ -25,7 +26,7 @@ in
[ wezterm ] ++ # Terminal emulator [ wezterm ] ++ # Terminal emulator
[ firefox cinnamon.nemo gnome.file-roller cinnamon.nemo-fileroller imv vlc pavucontrol ] ++ # Basic graphical apps [ firefox cinnamon.nemo gnome.file-roller cinnamon.nemo-fileroller imv vlc pavucontrol ] ++ # Basic graphical apps
[ libreoffice signal-desktop element-desktop prismlauncher mumble gimp inkscape ] ++ # Personalized selection of graphical apps [ libreoffice signal-desktop element-desktop prismlauncher mumble gimp inkscape ] ++ # Personalized selection of graphical apps
# [ factorio ] ++ # Games [ (callPackage ./pkgs/mons/mons.nix {}) ] ++ # Games
[ bemenu j4-dmenu-desktop fcitx5-with-addons ] ++ # Sway- and Wayland-related packages [ bemenu j4-dmenu-desktop fcitx5-with-addons ] ++ # Sway- and Wayland-related packages
[ noto-fonts redhat-official-fonts overpass ibm-plex ] ++ # Fonts [ noto-fonts redhat-official-fonts overpass ibm-plex ] ++ # Fonts
[ papirus-icon-theme ] ++ # Icons [ papirus-icon-theme ] ++ # Icons
@ -74,7 +75,7 @@ in
# configure fonts correctly # configure fonts correctly
fonts.fontconfig.enable = true; fonts.fontconfig.enable = true;
xdg.configFile."fontconfig/conf.d/20-default.fonts.conf".source = ./config/20-default-fonts.conf; xdg.configFile."fontconfig/conf.d/20-default.fonts.conf".source = ./extra/20-default-fonts.conf;
# fix nemo terminal integration # fix nemo terminal integration
dconf.settings."org/cinnamon/desktop/applications/terminal".exec = "wezterm"; dconf.settings."org/cinnamon/desktop/applications/terminal".exec = "wezterm";

40
pkgs/mons/mons.nix Normal file
View file

@ -0,0 +1,40 @@
{
lib,
python311Packages,
fetchPypi,
}:
python311Packages.buildPythonPackage rec {
pname = "mons";
version = "2.0.0";
pyproject = true;
doCheck = false;
src = fetchPypi {
inherit pname version;
sha256 = "E1yBTwZ4T2C3sXoLGz0kAcvas0q8tO6Aaiz3SHrT4ZE=";
};
nativeCheckInputs = [];
nativeBuildInputs = [python311Packages.setuptools-scm];
propagatedBuildInputs = with python311Packages; [
dnfile
pefile
click
tqdm
xxhash
pyyaml
urllib3
platformdirs
setuptools
# Only required for python 3.9 and below
# typing_extensions
# importlib-resources
];
meta = {
description = "Command-Line Installer and Manager for Celeste Modding";
homepage = "https://github.com/coloursofnoise/mons";
license = lib.licenses.mit;
};
}

View file

@ -3,5 +3,9 @@
defaultEditor = true; defaultEditor = true;
viAlias = true; viAlias = true;
vimAlias = true; vimAlias = true;
withPython3 = true;
extraPython3Packages = pyPkgs: with pyPkgs; [
virtualenv
];
extraLuaConfig = builtins.readFile ./neovim/init.lua; extraLuaConfig = builtins.readFile ./neovim/init.lua;
} }

View file

@ -3,6 +3,8 @@
vim.opt.number = true vim.opt.number = true
vim.opt.syntax = 'on' vim.opt.syntax = 'on'
vim.opt.smartcase = true vim.opt.smartcase = true
vim.opt.statusline = "%F %{wordcount().words} words"
vim.opt.wrap = false -- don't wrap text
--- clipboard --- clipboard
vim.opt.clipboard = 'unnamedplus' vim.opt.clipboard = 'unnamedplus'
@ -29,12 +31,40 @@ plugins = {
"folke/neodev.nvim", "folke/neodev.nvim",
{ {
"neovim/nvim-lspconfig", "neovim/nvim-lspconfig",
["dependencies"] = { ["dependencies"] = { -- Dependencies define which plugins are loaded before this one
{ "j-hui/fidget.nvim", ["opts"] = {} }, { "j-hui/fidget.nvim", ["opts"] = {} },
{ "folke/neodev.nvim", ["opts"] = {} } { "folke/neodev.nvim", ["opts"] = {} }
}, },
["name"] = "nvim-lspconfig" ["name"] = "nvim-lspconfig"
}, },
{
"nvim-treesitter/nvim-treesitter",
["config"] = function(_, _)
require("nvim-treesitter.configs").setup({
["auto-install"] = true,
["highlight"] = {
["enable"] = true,
},
["incremental-selection"] = {
["enable"] = true,
},
})
end
},
{
"ms-jpq/coq_nvim",
["dependencies"] = {
"nvim-lspconfig",
{ "ms-jpq/coq.artifacts" },
{ "ms-jpq/coq.thirdparty" },
},
["config"] = function(_, _)
-- vim.g.coq_settings = {
-- ["xdg"] = true
-- }
-- coq.Now("--shut-up")
end
},
{ {
'AlexvZyl/nordic.nvim', 'AlexvZyl/nordic.nvim',
lazy = false, lazy = false,
@ -44,26 +74,29 @@ plugins = {
end end
}, },
"lervag/vimtex", "lervag/vimtex",
{ -- {
'nvim-lualine/lualine.nvim', -- 'nvim-lualine/lualine.nvim',
dependencies = { 'nvim-tree/nvim-web-devicons' } -- dependencies = { 'nvim-tree/nvim-web-devicons' }
}, -- },
} }
require("lazy").setup(plugins) require("lazy").setup(plugins)
-- Configure nvim-lspconfig to work with servers -- Configure nvim-lspconfig to work with servers; configure coq to work with lsps
require'lspconfig'.ocamllsp.setup{} -- TODO put this in coq config block in lazy so it doesn't load every time!!!!!!!
local lspconfig = require('lspconfig')
local coq = require('coq')
lspconfig.ocamllsp.setup(coq.lsp_ensure_capabilities({}))
-- Configure vimtex -- Configure vimtex
vim.g.vimtex_view_method = "zathura" vim.g.vimtex_view_method = "zathura"
-- Configure lualine
require('lualine').setup { -- Configure lualine
options = { -- require('lualine').setup {
icons_enabled = true, -- options = {
theme = 'nord', -- icons_enabled = true,
-- theme = 'nord',
}, -- },
} -- }

2
todo
View file

@ -5,3 +5,5 @@ i3status bar
bluetooth setup bluetooth setup
media player daemon media player daemon
dmenu files dmenu files
background (used feh on i3)