For question 1: idk how to convert tex to svg, but maybe there’s a program called tex2svg . Often programs are named like that. However, if you want the contents of a file (which is basically markup text) in the clipboard from CLI you would use on Xorg X11 xclip or xclipboard like so:
xclip -selection clipboard -in < myfile.txt
… or on Wayland wl-copy from wl-clipboard like so:
wl-copy < myfile.txt
For question 3: after you have reviewed the potentially dangerous script, you would move it to a directory for non distribution files, eg. /usr/local/bin/ if it is for all users on your system. You would add that path to the PATH environment variable for all users who need it, but maybe better not for root. I mean you can, but make sure the permissions don’t allow non-root users to write or replace the file/dir so nobody can use it to escalate their privileges.
In Wayland, window managers are usually called compositors, though. There aren’t many good. I thought about making one, but the keyboard layout stuff seems not to work out-of-the-box with the reference compositor Weston, which made me pause my efforts.