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

plugins/typescript-tools: init + test #966

Merged
merged 1 commit into from
Jan 26, 2024

Conversation

garaiza-93
Copy link
Contributor

@garaiza-93 garaiza-93 commented Jan 23, 2024

@GaetanLepage
Copy link
Member

Thank you for taking a shot at this one :)

@garaiza-93
Copy link
Contributor Author

Felt right since you're already working on rustacean for me :p

@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch from 834b878 to ba85593 Compare January 24, 2024 01:51
@garaiza-93
Copy link
Contributor Author

I've added most of the settings. There's a hurdle though.
How could I add handlers without wanting to tear my hair out? Looking at typescript-tools readme it is a list of variables (or attributes in Nix's case). There's a number of supported methods too, and I hope I don't have to add these one-by-one!!

@GaetanLepage
Copy link
Member

How could I add handlers without wanting to tear my hair out?

handlers = mkOption {
  type = with helpers.nixvimTypes; nullOr (attrsOf strLuaFn);
  apply = v: helpers.ifNonNull' v (mapAttrs (_: helpers.mkRaw) v);
  default = null;
  description = "...";
  example = {
    "textDocument/publishDiagnostics" = ''
      api.filter_diagnostics(
        -- Ignore 'This may be converted to an async function' diagnostics.
        { 80006 }
      )
    '';
  };
};

plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch 5 times, most recently from fc7a18f to 75c158e Compare January 24, 2024 20:31
@garaiza-93 garaiza-93 marked this pull request as ready for review January 24, 2024 20:33
@garaiza-93 garaiza-93 changed the title WIP adding typescript-tools plugins/typescript-tools: init + test Jan 24, 2024
@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch from 75c158e to 8d5af18 Compare January 24, 2024 20:34
@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch 2 times, most recently from 8204dd4 to 88aa611 Compare January 24, 2024 22:22
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
plugins/languages/typescript-tools.nix Outdated Show resolved Hide resolved
@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch 2 times, most recently from 8e6b578 to da9500d Compare January 25, 2024 19:12
@garaiza-93 garaiza-93 requested a review from traxys January 25, 2024 19:16
Added most top-level settings

add rest of the options, create test

remove line

change option for onAttach

some bugfixes, remove onAttach option and set it in options

bugfixes

change types, use enums instead of nullable strings

Add description

requested changes

allow for a list of enums

make option for on_attach function
@garaiza-93 garaiza-93 force-pushed the add-typescript-tools branch from da9500d to c15e4dd Compare January 25, 2024 19:31
@traxys traxys merged commit 56b1082 into nix-community:main Jan 26, 2024
39 checks passed
@garaiza-93 garaiza-93 deleted the add-typescript-tools branch January 26, 2024 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[PLUGIN REQUEST] typescript-tools
3 participants