Civix: how to install and generate a skeletal extension (drupal)
The main civix download is a PHAR archive. You can generally execute a PHAR archive directly, without extracting it, as described in the README:

sudo curl -LsS https://download.civicrm.org/civix/civix.phar -o /usr/local/bin/civix
sudo chmod +x /usr/local/bin/civix


If it's a typical Debian/Ubuntu/RedHat server which you fully control, then putting the file in /usr/local/bin/ is handy. However, this is not required: as far as civix is concerned, you can put the file in any folder with any owner. For convenience, add the folder to the PATH.

Note: Some server admins/distros set up their own funky rules (e.g. via mount options or apparmor or disabling PHP extensions whatever) -- this is especially true on shared hosting. Unfortunately, only you and your admin can determine these types of things.