vercel / serve

Static file serving and directory listing
https://npmjs.com/package/serve
MIT License
9.35k stars 687 forks source link

Remove xsel/clipboard functionality #770

Open markg85 opened 1 year ago

markg85 commented 1 year ago

Description

I know, -n disables the clipboard functionality.

I'd say that having this feature at all - and for those that don't add -n - will cause unexpected behavior. That along with the why section below makes that i'm requesting to remove this feature entirely.

Why

Don't touch the clipboard unless explicitly invoked by keys that should have clipboard interaction. Like CTRL+C/X/V, etc. Being friendly with this feature will give the added side effect that the next paste someone does is whatever the serve command added. In my opinion this is a pattern that should not exist. If a user wants to copy the line, they will do so themselves.

Also, in my case specifically, i'm having my dev data/programs in a headless environment with my IDE using that environment. For that case too, i need no clipboard help.

Alternatives

Nothing from the serve side.

OldStarchy commented 1 year ago

I vote to invert the flag