This script fetches all of the files from the currently deployed version of a Firebase Hosting site. You must be signed in via the Firebase CLI and have "Site Viewer" permission on the site in question to be able to properly run the script.
env FIREBASE_TOKEN=`cat <file_where_firebasetoken is saved>` fetchFiles.js <my-site>
Where <site_name>
is your Firebase Hosting site (e.g. my-site
from my-site.firebaseapp.com
).
The files will be downloaded into a folder <site_name>_<version_id>
where the version ID is the
current version of your site.
node --version
v16.13.0
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.3 LTS
Release: 20.04
Codename: focal
uname -vosri
Linux 4.4.0-19041-Microsoft #1237-Microsoft Sat Sep 11 14:32:00 PST 2021 x86_64 GNU/Linux