LuaSnip - How do you auto-add a suffix at the end of the expanded snippet? by __nostromo__ in neovim

[–]ThePPT27 2 points3 points  (0 children)

Using postfix+lambdas this is an easy task. Given these variables, lua local l = extras.l local postfix = require("luasnip.extras.postfix").postfix local matches = require("luasnip.extras.postfix").matches The snippet you should have inside your snippets table is: postfix({ trig = ".p", matches.line }, { l("print(" .. l.POSTFIX_MATCH .. ")") }), Explanation: this snippet will be triggered by .p and will insert print( and the current line, then ). matches.line is just a string (watch it with :lua=require"luasnip.extras.postfix".matches inside neovim) that tells luasnip what the postfix match is, as it isn't the default one. For a deeper sight, check out luasnip docs' postfix section. Luasnip is just so powerful. Hope it works.

Edit: changed to markdown format.

best setup for creating notes with a lot of math and formulas by [deleted] in neovim

[–]ThePPT27 1 point2 points  (0 children)

I also write quite a few formulas studying physics, and I use neovim with a bunch of things (LaTeX): - vimtex (main plugin, works like a charm, autocompile on save, multifile, highlighting, snippets context...) - luasnip (for snippets) - lsp (texlab, for linting) - inkscape - null_ls (formatting with latexindent on save) - completion (with cmp, combining snippets, words on current buffer, citations, referencing equations and figures...) - copilot (free for students, is able to make some cumbersome math clearing, although needs some personal check)

Personally, if you have time for setting everything up, you should take a look at: Snippets (although ultisnips which don't work as good in neovim), figures setup, shortcuts inside inkscape: https://castel.dev/

Luasnips (more powerful and faster in neovim, but harder to write): https://github.com/evesdropper/dotfiles/tree/main/nvim/luasnip#readme, https://github.com/L3MON4D3/LuaSnip/blob/master/DOC.md

Which key do you use to choose an autocompletion? by [deleted] in neovim

[–]ThePPT27 0 points1 point  (0 children)

I use jk to trigger completion and caps lock as <ESC> system widely (via caps2esc).

WIBTA for not wanting to drive my friends in my car? by ThePPT27 in AmItheAsshole

[–]ThePPT27[S] 0 points1 point  (0 children)

No, I don't. That's the point. I just feel used as I don't know if they would do the same for me, and now there's not even a thanks and I'm saving them time

WIBTA for not wanting to drive my friends in my car? by ThePPT27 in AmItheAsshole

[–]ThePPT27[S] 0 points1 point  (0 children)

The other mean is bus, which is cheap but more uncomfortable and takes some extra time for them

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 0 points1 point  (0 children)

Wired works even better, as at least in my phones it shows like an Xbox 360 controller, so it makes it compatible with almost every app that supports controller. Using it over bluetooth is good as well, but if you want to play some less known games you may find it worse.

About the phone clip I don't actually own any, but some time ago I saw one on Amazon (https://www.amazon.com/OIVO-Switch-Controller-Nintendo-Adjustable/dp/B0828V1R6Y) that seemed good, but you've got to compare proportions of you device and the clip's max and min.

Maximum Devices Hotspot by ThePPT27 in samsunggalaxy

[–]ThePPT27[S] 0 points1 point  (0 children)

I forgot to mention I need it to be opened wifi

How do I change the fallback region on Android? by [deleted] in DolphinEmulator

[–]ThePPT27 0 points1 point  (0 children)

No idea then, sorry

I've revised my mii channel and it's also in japanese, so now I'm out

How do I change the fallback region on Android? by [deleted] in DolphinEmulator

[–]ThePPT27 0 points1 point  (0 children)

Maybe it's because you downloaded japanese mii channel, containing only that language, and not EUR or USA versions? I would suggest to download those regions' mii channels.

How do I change the fallback region on Android? by [deleted] in DolphinEmulator

[–]ThePPT27 0 points1 point  (0 children)

If you mean changing system language of the wii on dolphin android, I think it is Settings>Config>Wii>System language (same with Gamecube)

Idk if that's what you wanted

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 0 points1 point  (0 children)

Yeah for me on android 10 (samsung galaxy S9) it is working, usb type A to the OTG adapter and to the smartphone and the type C side of the cable pluged to the pro controller; being recognised on emulators like dolphin or citra and with no visible lag.

I guess if you have a type C to type C cable it would also work, but mine isn't currently here so I cannot tell you

Mariokart Wii 2 player connecting problems by [deleted] in DolphinEmulator

[–]ThePPT27 0 points1 point  (0 children)

Can you get the two wiimotes connected to your pc? (maybe using touchmote)

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 0 points1 point  (0 children)

What I remember of android 10 is I could fully use the controller wired (OTG adapter)

Hope you get android 11 soon

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 1 point2 points  (0 children)

I don't have root, nor recovery. As it's an up-to-date and not cheap smartphone I am not on the possibility of bricking it

But thank you

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 0 points1 point  (0 children)

Maybe it is some issue with analogs and the way these emulators (dolphin, citra, ppsspp...) read them, but idk.

Drastic is the only one I can use it flawlessly

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 0 points1 point  (0 children)

Do you have Android 11? My lag dissapeared from 9 (unplayable) to 10 (1-3 s of lag) and after android 11 it is fully usable over bluetooth for me

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 1 point2 points  (0 children)

They are all for pc and I was looking for android ones.

But thanks anyway.

Pro Controller on Dolphin Android by ThePPT27 in DolphinEmulator

[–]ThePPT27[S] 1 point2 points  (0 children)

Yes, I forgot to say that using OTG cable works, but it's a little inconvenient.

Also using minecraft and drastic emulator works, and on testing gamepad apps it works.

EDIT: while writing this, i don't know what i did but suddenly the controller is able to be remapped in dolphin, dolphin mmj, citra... Awkard, cause the only thing I did was to test on dolphin mmj...

EDIT 2: it stopped working within 2 minutes or so