vimspector
                                
                                
                                
                                    vimspector copied to clipboard
                            
                            
                            
                        Enable PID picker injection
Fundamentally, this is the code you sketched.
I'm not sure how to test it. I guess by inspection we can be sure it doesn't alter the current behavior.
Whether a customization actually works I guess is another story. But that's maybe ok, as in, the user has to make sure to write an appropriate function to make it work.
Anyway, I have this in my vimrc to make use of it:
let g:vimspector_custom_process_picker = 'PickProcess()'
function! PickProcess() abort
  return str2nr(split(fzf#run({'source': 'ps -e'})[0])[0])
endfunction
which I think could go in an example in the doc.
If you are happy with it, I can do it.
I'm totally fine with updating the doc, but I'd do it only after having the tests in place, as without those I don't think you're gonna accept anything. And... I guess I'd need at least some guidance to make the tests :D
there's info on the test framework here https://github.com/puremourning/vimspector/blob/master/CONTRIBUTING.md#pr-guidelines
I suspect that the way to test this is to write a test that sets the option to some function implemented by the test script and assert that is called etc.
This pull request introduces 1 alert when merging 890cdbbf4f2bbf17afc656f012e40441073ff737 into c95ad4c8fb54adb75ceb0397ef6ace1c4eec3790 - view on LGTM.com
new alerts:
- 1 for Duplication in regular expression character class
 
I've just tried it. It looks ok to me. Always ready to write the doc.
This pull request introduces 1 alert when merging 028bb0b62e8aed08f230a342d2797a68855513b4 into 5c328b513485675c061558d2f25a98ee503cb243 - view on LGTM.com
new alerts:
- 1 for Duplication in regular expression character class
 
I'd still like to provide something in this space, but I'm still not super happy with the result currently. I'll leave this open as a reminder to look into it.
Just fyi I haven't forgotten about this, I still intend to so something here, I'm just still not sure what is best.
Actually hold on, because I had another thought about it. I'll find some time to write to you in the chat in the afternoon.
Implemented in #773