When running npm install -g https://github.com/ETCDEVTeam/emerald.git as instructed in the README, this error appears:

When trying with sudo npm install -g https://github.com/ETCDEVTeam/emerald.git a different one appears:

Is the README up to date or are there other configuration steps?
Node v8.4.0
NPM v5.3.0
Ubuntu v14.04.5