I don't have e.g. Helvetica, yet would like to use its clone that can be used with pdflatex, but instead use it with xelatex. I have tried
\usepackage{fontspec}
\usepackage{helvet}
\newfontfamily{\phv}{Helvetica}
Which tells me fontspec can't find Helvetica.
\usepackage{fontspec}
\newfontfamily{\arial}{Arial}
\usepackage{sectsty}
\allsectionsfont{\arial}
Which works, since I'm on a windows machine and arial is installed.
%\usepackage{fontspec}
\usepackage{helvet}
\newfontfamily{\phv}{Helvetica}
Which works with pdflatex. Switching back
\documentclass{article}
\usepackage{fontspec}
\setmainfont{Libertinus Serif}
\usepackage{helvet}
\setsansfont{Helvetica} % <-- doesn't work, since I don't have the font installed on my system
%\newfontfamily{\phv}{Helvetica}
\renewcommand{\familydefault}{\sfdefault}
\section{first section}
some text which should be in helvetica
\end{document}
MWE that I wish to be working:
\documentclass{article}
\usepackage{fontspec}
\usepackage{helvet}
\newfontfamily{\phv}{Helvetica}
\usepackage{sectsty}
\allsectionsfont{\phv}
\begin{document}
\section{first section}
some text which should not be in helvetica
\end{document}
I'm sorry, but I won't take the time to get into LuaTeX atm. I'm at a loss as to what I should try, and how, and in which order.

texlive/2018/texmf-dist/fonts/opentype/public/tex-gyre/texgyreheros-regular.otf. If you are on linux you need to enable the name search for xetex (https://www.tug.org/texlive/doc/texlive-en/texlive-en.html#x1-340003.4.4), or use file names instead. Or simply use lualatex which will work out-of-box. – Ulrike Fischer May 15 '18 at 14:37