Skip to content

Commit

Permalink
feat: multi-repo setup based on mini.nvim
Browse files Browse the repository at this point in the history
  • Loading branch information
Saghen committed Jul 31, 2024
1 parent 24422f2 commit 15e808b
Show file tree
Hide file tree
Showing 32 changed files with 83 additions and 668 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
target/
.archive.lua
dual/
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion lua/blink/cmp/README.md → README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
- Simple hackable codebase
- Updates on every keystroke (0.5-4ms non-blocking, single core)
- Typo resistant fuzzy with frecncy and proximity bonus
- Extensive LSP support (tracker)
- Extensive LSP support ([tracker](./lsp-support-tracker.md))
- Snippet support (including `friendly-snippets`)
- TODO: Cmdline support
- External sources support (including `nvim-cmp` compatibility layer)
Expand Down
File renamed without changes.
File renamed without changes.
59 changes: 19 additions & 40 deletions flake.lock

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

70 changes: 62 additions & 8 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -1,13 +1,23 @@
{
description = "Set of simple, performant neovim plugins";
description = "Super amazing neovim completion plugin";

inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
nixpkgs.url = "github:cachix/devenv-nixpkgs/rolling";
devenv.url = "github:cachix/devenv";
flake-parts.url = "github:hercules-ci/flake-parts";
fenix.url = "github:nix-community/fenix";
fenix.inputs.nixpkgs.follows = "nixpkgs";
};

outputs = inputs@{ flake-parts, nixpkgs, ... }:
nixConfig = {
extra-trusted-public-keys =
"devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=";
extra-substituters = "https://devenv.cachix.org";
};

outputs = inputs@{ flake-parts, nixpkgs, fenix, ... }:
flake-parts.lib.mkFlake { inherit inputs; } {
imports = [ inputs.devenv.flakeModule ];
systems = [
"x86_64-linux"
"i686-linux"
Expand All @@ -18,15 +28,59 @@

perSystem = { config, self', inputs', pkgs, system, lib, ... }: {
# define the packages provided by this flake
packages = {
blink-nvim = pkgs.vimUtils.buildVimPlugin {
pname = "blink-nvim";
version = "2024-07-25";
packages = let
toolchain = fenix.packages.${system}.minimal.toolchain;
rustPlatform = pkgs.makeRustPlatform {
cargo = toolchain;
rustc = toolchain;
};
fuzzy = rustPlatform.buildRustPackage {
pname = "blink-cmp-lib";
version = "2024-07-26";

src = ./.;

cargoLock = {
lockFile = ./Cargo.lock;
outputHashes = {
"c-marshalling-0.2.0" =
"sha256-eL6nkZOtuLLQ0r31X7uroUUDYZsWOJ9KNXl4NCVNRuw=";
"frizbee-0.1.0" =
"sha256-+Os6ioFXB2K86V/8Z2xNxmO7jo3RLC9VKpuztQRrIgE=";
};
};
};
in {
blink-cmp = pkgs.vimUtils.buildVimPlugin {
pname = "blink-cmp";
version = "2024-07-26";

src = ./.;

preInstall = ''
mkdir -p target/release
ln -s ${fuzzy}/lib/libblink_cmp_fuzzy.so target/release/libblink_cmp_fuzzy.so
'';

default = self'.packages.blink-nvim;
meta = {
description = "Super amazing neovim completion plugin";
homepage = "https://github.com/saghen/blink.cmp";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ redxtech ];
};
};

default = self'.packages.blink-cmp;
};

# define the default dev environment
devenv.shells.default = {
name = "fuzzy";

languages.rust = {
enable = true;
channel = "nightly";
};
};
};
};
Expand Down
File renamed without changes.
21 changes: 0 additions & 21 deletions lua/blink/cmp/LICENSE

This file was deleted.

File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 15e808b

Please sign in to comment.