Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update flake, add vimwiki #56

Merged
merged 11 commits into from
Apr 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
os: [macos-latest, ubuntu-latest]
steps:
- uses: actions/checkout@v2.4.0
- uses: cachix/install-nix-action@v18
- uses: cachix/install-nix-action@v20
with:
extra_nix_config: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
Expand Down
4 changes: 3 additions & 1 deletion dotfiles/neovim/init.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
-- init.lua
-- this file shoul dhold only things that don't go with other things
-- this file should hold only things that don't go with other things
-- for instance, there's only one configuration that has to do with Markdown previewing --
-- this wouldn't make sense to put in a markdown preview config, because there's nothinge else
-- that would go there.
Expand All @@ -10,6 +10,8 @@ require("completion-config")
require("custom-jq-config")
require("custom-lsp-config")
require("custom-orgmode")
require("custom-vimwiki")
require("custom-which-key")
require("fzf-config")
require("git-config")
require("tree-config")
Expand Down
4 changes: 4 additions & 0 deletions dotfiles/neovim/lua/custom-vimwiki.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-- add a binding for generating table of contents
vim.api.nvim_set_keymap("n", "<leader>wlb", "<cmd>VimwikiBacklinks<CR>", { noremap = true })
vim.api.nvim_set_keymap("n", "<leader>wlc", "<cmd>VimwikiCheckLinks<CR>", { noremap = true })
vim.api.nvim_set_keymap("n", "<leader>wc", "<cmd>VimwikiTOC<CR>", { noremap = true })
4 changes: 4 additions & 0 deletions dotfiles/neovim/lua/custom-which-key.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
require("which-key").setup { }

-- add a binding to open the interactive which-key popup
vim.api.nvim_set_keymap("n", "<leader>k", "<cmd>WhichKey<CR>", { noremap = true })
39 changes: 39 additions & 0 deletions dotfiles/neovim/vimwiki-templates/default.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<html>
<head>
<title>%title%</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<!-- Bootstrap or materialize -->
<!-- <link href="https://maxcdn.bootstrapcdn.com/bootswatch/3.3.7/darkly/bootstrap.min.css" rel="stylesheet" integrity="sha384-S7YMK1xjUjSpEnF4P8hPUcgjXYLZKK3fQW1j5ObLSl787II9p8RO9XUGehRmKsxd" crossorigin="anonymous"> -->
<!-- <link href="%root_path%css/bootstrap-theme.min.css" rel="stylesheet" > -->
<!-- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.8/css/materialize.min.css"> -->

<!-- Roboto Font -->
<!-- <link href='%root_path%css/roboto.css' rel='stylesheet' type='text/css'> -->

<!-- Code Prettify -->
<!-- <script async src="%root_path%js/code-prettify.js"></script> -->

<!-- Some CSS, for removing Code prettify borders -->
</head>
<body>

<!--
<nav class="navbar navbar-inverse">
<ul class="nav navbar-nav">
<li><a class ="title" href="#">Vim Wiki</a></li>
<li><a class = "nav-item"href="%root_path%index.html">Index</a></li>
</ul>
</div>
</nav>
-->


<div class="container">
%content%
</div>


</body>
</html>

24 changes: 12 additions & 12 deletions flake.lock

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

6 changes: 5 additions & 1 deletion home.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ let
pkgs.htop
pkgs.httpie
pkgs.imagemagick
pkgs.pandoc
pkgs.wget
];

Expand Down Expand Up @@ -97,6 +98,7 @@ in
plugins =
with pkgs.vimPlugins;
[
(nvim-treesitter.withPlugins treesitterGrammars)
cmp-buffer
cmp-nvim-lsp
cmp-treesitter
Expand All @@ -112,16 +114,18 @@ in
nvim-lspconfig
nvim-metals
nvim-tree-lua
(nvim-treesitter.withPlugins treesitterGrammars)
nvim-web-devicons
orgmode
plenary-nvim
purescript-vim
vim-colors-solarized
vim-nix
vimwiki
which-key-nvim
];
extraPackages = with pkgs; [
dhall-lsp-server
discount # maybe not needed? try removing once template source location config is working
fzf
kotlin-language-server
nodePackages.typescript-language-server
Expand Down