Unverified Commit 2280d540 authored by Gaétan Lepage's avatar Gaétan Lepage Committed by GitHub
Browse files

vimPlugins.avante-nvim: 2024-10-18 -> 2024-11-04 (#353494)

parents fe6dfbe5 cc3c24dd
Loading
Loading
Loading
Loading
+0 −1778

File deleted.

Preview size limit exceeded, changes collapsed.

+0 −75
Original line number Diff line number Diff line
{
  lib,
  rustPlatform,
  fetchFromGitHub,
  pkg-config,
  openssl,
  stdenv,
  vimUtils,
  darwin,
}:

let
  version = "2024-10-18";

  src = fetchFromGitHub {
    owner = "yetone";
    repo = "avante.nvim";
    rev = "36b23cef16c2c624c34bea213f01c06782d2ca40";
    hash = "sha256-QUFcJMbfr5BAS04ig1IHLCMLACeQhFVH9ZCH/VD8i8Y=";
  };

  meta = with lib; {
    description = "Neovim plugin designed to emulate the behaviour of the Cursor AI IDE";
    homepage = "https://github.com/yetone/avante.nvim";
    license = licenses.asl20;
    maintainers = with lib.maintainers; [
      ttrei
      aarnphm
    ];
  };

  avante-nvim-lib = rustPlatform.buildRustPackage {
    pname = "avante-nvim-lib";
    inherit version src meta;
    cargoLock = {
      lockFile = ./Cargo.lock;
      outputHashes = {
        "mlua-0.10.0-beta.1" = "sha256-ZEZFATVldwj0pmlmi0s5VT0eABA15qKhgjmganrhGBY=";
      };
    };

    nativeBuildInputs = [
      pkg-config
    ];

    buildInputs =
      [
        openssl
      ]
      ++ lib.optionals stdenv.hostPlatform.isDarwin [
        darwin.apple_sdk.frameworks.Security
      ];

    buildFeatures = [ "luajit" ];
  };
in

vimUtils.buildVimPlugin {
  pname = "avante.nvim";
  inherit version src meta;

  postInstall =
    let
      ext = stdenv.hostPlatform.extensions.sharedLibrary;
    in
    ''
      mkdir -p $out/build
      ln -s ${avante-nvim-lib}/lib/libavante_repo_map${ext} $out/build/avante_repo_map${ext}
      ln -s ${avante-nvim-lib}/lib/libavante_templates${ext} $out/build/avante_templates${ext}
      ln -s ${avante-nvim-lib}/lib/libavante_tokenizers${ext} $out/build/avante_tokenizers${ext}
    '';

  doInstallCheck = true;
  nvimRequireCheck = "avante";
}
+12 −0
Original line number Diff line number Diff line
@@ -18851,4 +18851,16 @@ final: prev:
    };
    meta.homepage = "https://github.com/jghauser/follow-md-links.nvim/";
  };
  avante-nvim = buildVimPlugin {
    pname = "avante.nvim";
    version = "2024-11-04";
    src = fetchFromGitHub {
      owner = "yetone";
      repo = "avante.nvim";
      rev = "5db2a0f92ff0ac4cfde27266cbc91eabdc2bb7f5";
      sha256 = "sha256-bLHKJfmn8a57U3WRrvib7yWUgO8PI1V0H77Q+xsGlfM=";
    };
    meta.homepage = "https://github.com/yetone/avante.nvim";
  };
}
+60 −8
Original line number Diff line number Diff line
@@ -166,14 +166,66 @@ in
    nvimRequireCheck = "autosave";
  };

  avante-nvim = (callPackage ./avante-nvim { }).overrideAttrs {
  avante-nvim = super.avante-nvim.overrideAttrs (
    oldAttrs:
    let
      avante-nvim-lib = rustPlatform.buildRustPackage {
        pname = "avante-nvim-lib";
        inherit (oldAttrs) version src;

        cargoHash = "sha256-Hh7qAmGtxfWtkBBsNq0iVTruUSe0duE4tXaajDIt8zQ=";

        nativeBuildInputs = [
          pkg-config
        ];

        buildInputs = [
          openssl
        ];

        buildFeatures = [ "luajit" ];

        checkFlags = [
          # Disabled because they access the network.
          "--skip=test_hf"
          "--skip=test_public_url"
          "--skip=test_roundtrip"
        ];
      };
    in
    {
      dependencies = with self; [
        dressing-nvim
        nui-nvim
        nvim-treesitter
        plenary-nvim
      ];

      postInstall =
        let
          ext = stdenv.hostPlatform.extensions.sharedLibrary;
        in
        ''
          mkdir -p $out/build
          ln -s ${avante-nvim-lib}/lib/libavante_repo_map${ext} $out/build/avante_repo_map${ext}
          ln -s ${avante-nvim-lib}/lib/libavante_templates${ext} $out/build/avante_templates${ext}
          ln -s ${avante-nvim-lib}/lib/libavante_tokenizers${ext} $out/build/avante_tokenizers${ext}
        '';

      doInstallCheck = true;
      nvimRequireCheck = "avante";

      meta = {
        description = "Neovim plugin designed to emulate the behaviour of the Cursor AI IDE";
        homepage = "https://github.com/yetone/avante.nvim";
        license = lib.licenses.asl20;
        maintainers = with lib.maintainers; [
          ttrei
          aarnphm
        ];
      };
    }
  );

  barbecue-nvim = super.barbecue-nvim.overrideAttrs {
    dependencies = with self; [
+1 −0
Original line number Diff line number Diff line
@@ -85,6 +85,7 @@ https://github.com/m4xshen/autoclose.nvim/,HEAD,
https://github.com/gaoDean/autolist.nvim/,,
https://github.com/vim-scripts/autoload_cscope.vim/,,
https://github.com/nullishamy/autosave.nvim/,HEAD,
https://github.com/yetone/avante.nvim/,HEAD,
https://github.com/rafi/awesome-vim-colorschemes/,,
https://github.com/AhmedAbdulrahman/aylin.vim/,,
https://github.com/ayu-theme/ayu-vim/,,