Yes, that should do it.
Here’s a useful page to read about pacman: https://endeavouros.com/docs/pacman/
You might also want to read the manual of pacman with command
man pacman
It is not the easiest stuff to read, but will give you a lot of information about how to use pacman.
As you probably know by now, pacman is a very important tool in any Arch based distro.