Files
grin-web-wallet/build.sh
2023-10-12 16:56:22 -07:00

311 lines
70 KiB
Bash
Executable File

# Copy files
rm -rf "./temp"
mkdir "./temp"
wget "https://github.com/NicolasFlamel1/mwcwallet.com/archive/refs/heads/master.zip"
unzip "./master"
cp -r "./mwcwallet.com-master/public_html/." "./temp/"
chmod 777 -R "./temp/"
# Get version
VERSION=$(grep -Po "(?<=VERSION_NUMBER = \").*(?=\";)" "./temp/backend/common.php")
# Compile index.html
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/index.html" > "./temp/index.html"
sed -i "/<link rel=\"preload\".*>/d" "./temp/index.html"
sed -i "/--><link rel=\"prefetch\".*><!--/d" "./temp/index.html"
sed -i "/<link .* rel=\"manifest\".*>/d" "./temp/index.html"
sed -i "/<meta name=\"msapplication-config\".*>/d" "./temp/index.html"
sed -i "/<meta name=\"msapplication-starturl\".*>/d" "./temp/index.html"
sed -i "/<link rel=\"alternate\".*>/d" "./temp/index.html"
sed -i "/<link rel=\"canonical\".*>/d" "./temp/index.html"
# Compile styles
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/btc/btc.css" > "./temp/fonts/btc/btc.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/eth/eth.css" > "./temp/fonts/eth/eth.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/font_awesome/font_awesome.css" > "./temp/fonts/font_awesome/font_awesome.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/grin/grin.css" > "./temp/fonts/grin/grin.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/epic/epic.css" > "./temp/fonts/epic/epic.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/mwc/mwc.css" > "./temp/fonts/mwc/mwc.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/fonts/open_sans/open_sans.css" > "./temp/fonts/open_sans/open_sans.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/styles/section.css" > "./temp/styles/section.css"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/styles/unlocked.css" > "./temp/styles/unlocked.css"
# Compile scripts
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/scripts/camera_worker.js" > "./temp/scripts/camera_worker.js"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/scripts/output_worker.js" > "./temp/scripts/output_worker.js"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/scripts/slate_worker.js" > "./temp/scripts/slate_worker.js"
SERVER_NAME="mwcwallet.com" HTTPS="on" NO_FILE_VERSIONS="" NO_FILE_CHECKSUMS="" NO_MINIFIED_FILES="" HTTPS_SERVER_ADDRESS="https://mwcwallet.com" TOR_SERVER_ADDRESS="http://mwcwalletmiq3gdkmfbqlytxunvlxyli4m6zrqozk7xjc353ewqb6bad.onion" php "./mwcwallet.com-master/public_html/scripts/languages.js" > "./temp/scripts/languages.js"
# Inline images
sed -i "s#href=\"\./images/mask_images/mask_image\.svg\"#href=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/mask_images/mask_image.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/america\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/america.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/china\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/china.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/greece\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/greece.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/germany\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/germany.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/netherlands\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/netherlands.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/countries/czech_republic\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/countries/czech_republic.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#src=\"\./images/app_icons/app_icon\.svg\"#src=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-57x57\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-57x57.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-76x76\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-76x76.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-114x114\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-114x114.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-120x120\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-120x120.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-144x144\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-144x144.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-152x152\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-152x152.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-167x167\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-167x167.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/touch_icons/touch_icon-180x180\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/touch_icons/touch_icon-180x180.png" | openssl base64 -A`\"#g" "./temp/index.html"
sed -i "s#href=\"\./favicon\.ico\"#href=\"data:image/x-icon;base64,`cat "./mwcwallet.com-master/public_html/favicon.ico" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-16x16\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-16x16.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-24x24\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-24x24.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-32x32\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-32x32.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-48x48\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-48x48.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-64x64\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-64x64.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-114x114\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-114x114.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-120x120\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-120x120.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-128x128\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-128x128.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-144x144\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-144x144.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-152x152\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-152x152.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-180x180\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-180x180.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-192x192\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-192x192.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon-256x256\.png\"#href=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon-256x256.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#href=\"\./images/app_icons/app_icon\.svg\"#href=\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/app_icons/app_icon.svg" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#content=\"\./images/tile_images/tile_image-70x70\.png\"#content=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/tile_images/tile_image-70x70.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#content=\"\./images/tile_images/tile_image-150x150\.png\"#content=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/tile_images/tile_image-150x150.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#content=\"\./images/tile_images/tile_image-310x150\.png\"#content=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/tile_images/tile_image-310x150.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#content=\"\./images/tile_images/tile_image-310x310\.png\"#content=\"data:image/png;base64,`cat "./mwcwallet.com-master/public_html/images/tile_images/tile_image-310x310.png" | openssl base64 -A`\"#" "./temp/index.html"
sed -i "s#url(\"\./images/logo_big\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/logo_big.svg" | openssl base64 -A`\")#" "./temp/index.html"
sed -i "s#url(\"\./images/logo_small\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/logo_small.svg" | openssl base64 -A`\")#" "./temp/index.html"
sed -i "s#url(\"\.\./images/circle\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/circle.svg" | openssl base64 -A`\")#" "./temp/styles/section.css"
sed -i "s#url(\"\.\./images/down_arrow\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/down_arrow.svg" | openssl base64 -A`\")#" "./temp/styles/section.css"
sed -i "s#url(\"\.\./images/logo_small\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/logo_small.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#url(\"\.\./images/whale\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/whale.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#url(\"\.\./images/ledger\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/ledger.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#url(\"\.\./images/trezor\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/trezor.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#url(\"\.\./images/usb\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/usb.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#url(\"\.\./images/bluetooth\.svg\")#url(\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/bluetooth.svg" | openssl base64 -A`\")#" "./temp/styles/unlocked.css"
sed -i "s#\"\.\" + getResource(StartupImagesCreator\.LOGO_FILE_LOCATION)#\"data:image/svg+xml;base64,`cat "./mwcwallet.com-master/public_html/images/logo_small.svg" | openssl base64 -A`\"#" "./temp/scripts/startup_images_creator.js"
# Inline shaders
sed -i "s#\"\.\" + getResource(Logo\.VERTEX_SHADER_FILE_LOCATION)#\"data:text/plain;base64,`cat "./mwcwallet.com-master/public_html/shaders/logo.vert" | openssl base64 -A`\"#" "./temp/scripts/logo.js"
sed -i "s#\"\.\" + getResource(Logo\.FRAGMENT_SHADER_FILE_LOCATION)#\"data:text/plain;base64,`cat "./mwcwallet.com-master/public_html/shaders/logo.frag" | openssl base64 -A`\"#" "./temp/scripts/logo.js"
# Inline models
sed -i -f - "./temp/scripts/logo.js" << EOF
s#"\." + getResource(Logo\.MODEL_FILE_LOCATION)#"data:application/json;base64,`cat "./mwcwallet.com-master/public_html/models/mwc.json" | openssl base64 -A`"#
EOF
# Inline fonts
sed -i "s#url(\"\.\./\.\./fonts/btc/btc\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/btc/btc.woff" | openssl base64 -A`\")#" "./temp/fonts/btc/btc.css"
sed -i "s#url(\"\.\./\.\./fonts/btc/btc\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/btc/btc.woff2" | openssl base64 -A`\")#" "./temp/fonts/btc/btc.css"
sed -i "s#url(\"\.\./\.\./fonts/eth/eth\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/eth/eth.woff" | openssl base64 -A`\")#" "./temp/fonts/eth/eth.css"
sed -i "s#url(\"\.\./\.\./fonts/eth/eth\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/eth/eth.woff2" | openssl base64 -A`\")#" "./temp/fonts/eth/eth.css"
sed -i "s#url(\"\.\./\.\./fonts/font_awesome/font_awesome-5\.15\.4\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/font_awesome/font_awesome-5.15.4.woff" | openssl base64 -A`\")#" "./temp/fonts/font_awesome/font_awesome.css"
sed -i "s#url(\"\.\./\.\./fonts/font_awesome/font_awesome-5\.15\.4\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/font_awesome/font_awesome-5.15.4.woff2" | openssl base64 -A`\")#" "./temp/fonts/font_awesome/font_awesome.css"
sed -i -f - "./temp/fonts/font_awesome/font_awesome.css" << EOF
s#url("\.\./\.\./fonts/font_awesome/font_awesome_solid-5\.15\.4\.woff")#url("data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/font_awesome/font_awesome_solid-5.15.4.woff" | openssl base64 -A`")#
EOF
sed -i "s#url(\"\.\./\.\./fonts/font_awesome/font_awesome_solid-5\.15\.4\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/font_awesome/font_awesome_solid-5.15.4.woff2" | openssl base64 -A`\")#" "./temp/fonts/font_awesome/font_awesome.css"
sed -i "s#url(\"\.\./\.\./fonts/grin/grin\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/grin/grin.woff" | openssl base64 -A`\")#" "./temp/fonts/grin/grin.css"
sed -i "s#url(\"\.\./\.\./fonts/grin/grin\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/grin/grin.woff2" | openssl base64 -A`\")#" "./temp/fonts/grin/grin.css"
sed -i "s#url(\"\.\./\.\./fonts/epic/epic\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/epic/epic.woff" | openssl base64 -A`\")#" "./temp/fonts/epic/epic.css"
sed -i "s#url(\"\.\./\.\./fonts/epic/epic\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/epic/epic.woff2" | openssl base64 -A`\")#" "./temp/fonts/epic/epic.css"
sed -i "s#url(\"\.\./\.\./fonts/mwc/mwc\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/mwc/mwc.woff" | openssl base64 -A`\")#" "./temp/fonts/mwc/mwc.css"
sed -i "s#url(\"\.\./\.\./fonts/mwc/mwc\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/mwc/mwc.woff2" | openssl base64 -A`\")#" "./temp/fonts/mwc/mwc.css"
sed -i "s#url(\"\.\./\.\./fonts/open_sans/open_sans-1\.10\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/open_sans/open_sans-1.10.woff" | openssl base64 -A`\")#" "./temp/fonts/open_sans/open_sans.css"
sed -i "s#url(\"\.\./\.\./fonts/open_sans/open_sans-1\.10\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/open_sans/open_sans-1.10.woff2" | openssl base64 -A`\")#" "./temp/fonts/open_sans/open_sans.css"
sed -i "s#url(\"\.\./\.\./fonts/open_sans/open_sans_semibold-1\.10\.woff\")#url(\"data:font/woff;base64,`cat "./mwcwallet.com-master/public_html/fonts/open_sans/open_sans_semibold-1.10.woff" | openssl base64 -A`\")#" "./temp/fonts/open_sans/open_sans.css"
sed -i "s#url(\"\.\./\.\./fonts/open_sans/open_sans_semibold-1\.10\.woff2\")#url(\"data:font/woff2;base64,`cat "./mwcwallet.com-master/public_html/fonts/open_sans/open_sans_semibold-1.10.woff2" | openssl base64 -A`\")#" "./temp/fonts/open_sans/open_sans.css"
# Inline WASM
sed -i "s#\"\.\" + getResource(\"\./scripts/secp256k1-zkp-0\.0\.29\.wasm\")#\"data:application/wasm;base64,`cat "./mwcwallet.com-master/public_html/scripts/secp256k1-zkp-0.0.29.wasm" | openssl base64 -A`\"#" "./temp/scripts/secp256k1-zkp-0.0.29.js"
sed -i "s#\"\.\" + getResource(\"\./scripts/BLAKE2b-0\.0\.2\.wasm\")#\"data:application/wasm;base64,`cat "./mwcwallet.com-master/public_html/scripts/BLAKE2b-0.0.2.wasm" | openssl base64 -A`\"#" "./temp/scripts/BLAKE2b-0.0.2.js"
sed -i "s#\"\.\" + getResource(\"\./scripts/Ed25519-0\.0\.22\.wasm\")#\"data:application/wasm;base64,`cat "./mwcwallet.com-master/public_html/scripts/Ed25519-0.0.22.wasm" | openssl base64 -A`\"#" "./temp/scripts/Ed25519-0.0.22.js"
sed -i "s#\"\.\" + getResource(\"\./scripts/X25519-0\.0\.23\.wasm\")#\"data:application/wasm;base64,`cat "./mwcwallet.com-master/public_html/scripts/X25519-0.0.23.wasm" | openssl base64 -A`\"#" "./temp/scripts/X25519-0.0.23.js"
sed -i "s#\"\.\" + getResource(\"\./scripts/SMAZ-0\.0\.31\.wasm\")#\"data:application/wasm;base64,`cat "./mwcwallet.com-master/public_html/scripts/SMAZ-0.0.31.wasm" | openssl base64 -A`\"#" "./temp/scripts/SMAZ-0.0.31.js"
# Inline styles
sed -i -e "/<link .*\".\/fonts\/open_sans\/open_sans\.css\".*>/r ./temp/fonts/open_sans/open_sans.css" -e "/<link .*\".\/fonts\/open_sans\/open_sans\.css\".*>/i <style>" -e "/<link .*\".\/fonts\/open_sans\/open_sans\.css\".*>/a </style>" -e "/<link .*\".\/fonts\/open_sans\/open_sans\.css\".*>/d" "./temp/index.html"
sed -i -e "/<link .*\".\/fonts\/font_awesome\/font_awesome\.css\".*>/r ./temp/fonts/font_awesome/font_awesome.css" -e "/<link .*\".\/fonts\/font_awesome\/font_awesome\.css\".*>/i <style>" -e "/<link .*\".\/fonts\/font_awesome\/font_awesome\.css\".*>/a </style>" -e "/<link .*\".\/fonts\/font_awesome\/font_awesome\.css\".*>/d" "./temp/index.html"
sed -i -e "/<link .*\".\/styles\/normalize\.css-8\.0\.1\.css\".*>/r ./temp/styles/normalize.css-8.0.1.css" -e "/<link .*\".\/styles\/normalize\.css-8\.0\.1\.css\".*>/i <style>" -e "/<link .*\".\/styles\/normalize\.css-8\.0\.1\.css\".*>/a </style>" -e "/<link .*\".\/styles\/normalize\.css-8\.0\.1\.css\".*>/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/fonts\/mwc\/mwc\.css\".*><!--/r ./temp/fonts/mwc/mwc.css" -e "/--><link .*\".\/fonts\/mwc\/mwc\.css\".*><!--/i --><style>" -e "/--><link .*\".\/fonts\/mwc\/mwc\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/fonts\/mwc\/mwc\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/fonts\/btc\/btc\.css\".*><!--/r ./temp/fonts/btc/btc.css" -e "/--><link .*\".\/fonts\/btc\/btc\.css\".*><!--/i --><style>" -e "/--><link .*\".\/fonts\/btc\/btc\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/fonts\/btc\/btc\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/fonts\/eth\/eth\.css\".*><!--/r ./temp/fonts/eth/eth.css" -e "/--><link .*\".\/fonts\/eth\/eth\.css\".*><!--/i --><style>" -e "/--><link .*\".\/fonts\/eth\/eth\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/fonts\/eth\/eth\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/fonts\/grin\/grin\.css\".*><!--/r ./temp/fonts/grin/grin.css" -e "/--><link .*\".\/fonts\/grin\/grin\.css\".*><!--/i --><style>" -e "/--><link .*\".\/fonts\/grin\/grin\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/fonts\/grin\/grin\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/fonts\/epic\/epic\.css\".*><!--/r ./temp/fonts/epic/epic.css" -e "/--><link .*\".\/fonts\/epic\/epic\.css\".*><!--/i --><style>" -e "/--><link .*\".\/fonts\/epic\/epic\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/fonts\/epic\/epic\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/common\.css\".*><!--/r ./temp/styles/common.css" -e "/--><link .*\".\/styles\/common\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/common\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/common\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/tetris\.css\".*><!--/r ./temp/styles/tetris.css" -e "/--><link .*\".\/styles\/tetris\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/tetris\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/tetris\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/logo\.css\".*><!--/r ./temp/styles/logo.css" -e "/--><link .*\".\/styles\/logo\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/logo\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/logo\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/application\.css\".*><!--/r ./temp/styles/application.css" -e "/--><link .*\".\/styles\/application\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/application\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/application\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/unlocked\.css\".*><!--/r ./temp/styles/unlocked.css" -e "/--><link .*\".\/styles\/unlocked\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/unlocked\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/unlocked\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/sections\.css\".*><!--/r ./temp/styles/sections.css" -e "/--><link .*\".\/styles\/sections\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/sections\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/sections\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/section\.css\".*><!--/r ./temp/styles/section.css" -e "/--><link .*\".\/styles\/section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/settings_section\.css\".*><!--/r ./temp/styles/settings_section.css" -e "/--><link .*\".\/styles\/settings_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/settings_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/settings_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/about_section\.css\".*><!--/r ./temp/styles/about_section.css" -e "/--><link .*\".\/styles\/about_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/about_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/about_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/transaction_section\.css\".*><!--/r ./temp/styles/transaction_section.css" -e "/--><link .*\".\/styles\/transaction_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/transaction_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/transaction_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/account_section\.css\".*><!--/r ./temp/styles/account_section.css" -e "/--><link .*\".\/styles\/account_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/account_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/account_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/wallet_section\.css\".*><!--/r ./temp/styles/wallet_section.css" -e "/--><link .*\".\/styles\/wallet_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/wallet_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/wallet_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/send_payment_section\.css\".*><!--/r ./temp/styles/send_payment_section.css" -e "/--><link .*\".\/styles\/send_payment_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/send_payment_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/send_payment_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/log_section\.css\".*><!--/r ./temp/styles/log_section.css" -e "/--><link .*\".\/styles\/log_section\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/log_section\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/log_section\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/message\.css\".*><!--/r ./temp/styles/message.css" -e "/--><link .*\".\/styles\/message\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/message\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/message\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/install_app\.css\".*><!--/r ./temp/styles/install_app.css" -e "/--><link .*\".\/styles\/install_app\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/install_app\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/install_app\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/cookie_acceptance\.css\".*><!--/r ./temp/styles/cookie_acceptance.css" -e "/--><link .*\".\/styles\/cookie_acceptance\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/cookie_acceptance\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/cookie_acceptance\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/maintenance_notification\.css\".*><!--/r ./temp/styles/maintenance_notification.css" -e "/--><link .*\".\/styles\/maintenance_notification\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/maintenance_notification\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/maintenance_notification\.css\".*><!--/d" "./temp/index.html"
sed -i -e "/--><link .*\".\/styles\/language\.css\".*><!--/r ./temp/styles/language.css" -e "/--><link .*\".\/styles\/language\.css\".*><!--/i --><style>" -e "/--><link .*\".\/styles\/language\.css\".*><!--/a </style><!--" -e "/--><link .*\".\/styles\/language\.css\".*><!--/d" "./temp/index.html"
# Inline web workers
sed -i -e "/importScripts(\"\.\.\/scripts\/BLAKE2b-0\.0\.2\.js\");/r ./temp/scripts/BLAKE2b-0.0.2.js" -e "/importScripts(\"\.\.\/scripts\/BLAKE2b-0\.0\.2\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/Ed25519-0\.0\.22\.js\");/r ./temp/scripts/Ed25519-0.0.22.js" -e "/importScripts(\"\.\.\/scripts\/Ed25519-0\.0\.22\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/js-sha3-0\.8\.0\.js\");/r ./temp/scripts/js-sha3-0.8.0.js" -e "/importScripts(\"\.\.\/scripts\/js-sha3-0\.8\.0\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/js-sha256-0\.10\.0\.js\");/r ./temp/scripts/js-sha256-0.10.0.js" -e "/importScripts(\"\.\.\/scripts\/js-sha256-0\.10\.0\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/secp256k1-zkp-0\.0\.29\.js\");/r ./temp/scripts/secp256k1-zkp-0.0.29.js" -e "/importScripts(\"\.\.\/scripts\/secp256k1-zkp-0\.0\.29\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/SMAZ-0\.0\.31\.js\");/r ./temp/scripts/SMAZ-0.0.31.js" -e "/importScripts(\"\.\.\/scripts\/SMAZ-0\.0\.31\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/hi-base32-0\.5\.1\.js\");/r ./temp/scripts/hi-base32-0.5.1.js" -e "/importScripts(\"\.\.\/scripts\/hi-base32-0\.5\.1\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/bech32-2\.0\.0\.js\");/r ./temp/scripts/bech32-2.0.0.js" -e "/importScripts(\"\.\.\/scripts\/bech32-2\.0\.0\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/base58\.js\");/r ./temp/scripts/base58.js" -e "/importScripts(\"\.\.\/scripts\/base58\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/bignumber\.js-9\.1\.1\.js\");/r ./temp/scripts/bignumber.js-9.1.1.js" -e "/importScripts(\"\.\.\/scripts\/bignumber\.js-9\.1\.1\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/common\.js\");/r ./temp/scripts/common.js" -e "/importScripts(\"\.\.\/scripts\/common\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/consensus\.js\");/r ./temp/scripts/consensus.js" -e "/importScripts(\"\.\.\/scripts\/consensus\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/bit_reader\.js\");/r ./temp/scripts/bit_reader.js" -e "/importScripts(\"\.\.\/scripts\/bit_reader\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/bit_writer\.js\");/r ./temp/scripts/bit_writer.js" -e "/importScripts(\"\.\.\/scripts\/bit_writer\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/crypto\.js\");/r ./temp/scripts/crypto.js" -e "/importScripts(\"\.\.\/scripts\/crypto\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/tor\.js\");/r ./temp/scripts/tor.js" -e "/importScripts(\"\.\.\/scripts\/tor\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/mqs\.js\");/r ./temp/scripts/mqs.js" -e "/importScripts(\"\.\.\/scripts\/mqs\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slatepack\.js\");/r ./temp/scripts/slatepack.js" -e "/importScripts(\"\.\.\/scripts\/slatepack\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/uuid\.js\");/r ./temp/scripts/uuid.js" -e "/importScripts(\"\.\.\/scripts\/uuid\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/hash\.js\");/r ./temp/scripts/hash.js" -e "/importScripts(\"\.\.\/scripts\/hash\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slate\.js\");/r ./temp/scripts/slate.js" -e "/importScripts(\"\.\.\/scripts\/slate\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slate_participant\.js\");/r ./temp/scripts/slate_participant.js" -e "/importScripts(\"\.\.\/scripts\/slate_participant\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slate_input\.js\");/r ./temp/scripts/slate_input.js" -e "/importScripts(\"\.\.\/scripts\/slate_input\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slate_output\.js\");/r ./temp/scripts/slate_output.js" -e "/importScripts(\"\.\.\/scripts\/slate_output\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/slate_kernel\.js\");/r ./temp/scripts/slate_kernel.js" -e "/importScripts(\"\.\.\/scripts\/slate_kernel\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/identifier\.js\");/r ./temp/scripts/identifier.js" -e "/importScripts(\"\.\.\/scripts\/identifier\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/output\.js\");/r ./temp/scripts/output.js" -e "/importScripts(\"\.\.\/scripts\/output\.js\");/d" "./temp/scripts/slate_worker.js"
sed -i "/--><script .*\".\/scripts\/slate\.js\".*><!--/i --><script id=\"slate_worker\" type=\"javascript\/worker\">" "./temp/index.html"
sed -i -e "/--><script .*\"slate_worker\".*>/r ./temp/scripts/slate_worker.js" -e "/--><script .*\"slate_worker\".*>/a </script><!--" "./temp/index.html"
sed -i "s/Slate\.WORKER_FILE_LOCATION/window[\"URL\"].createObjectURL(new Blob([document\.getElementById(\"slate_worker\")[\"textContent\"]], {\"type\": \"application\/javascript\"}))/" "./temp/scripts/slate.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/BLAKE2b-0\.0\.2\.js\");/r ./temp/scripts/BLAKE2b-0.0.2.js" -e "/importScripts(\"\.\.\/scripts\/BLAKE2b-0\.0\.2\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/secp256k1-zkp-0\.0\.29\.js\");/r ./temp/scripts/secp256k1-zkp-0.0.29.js" -e "/importScripts(\"\.\.\/scripts\/secp256k1-zkp-0\.0\.29\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/bignumber\.js-9\.1\.1\.js\");/r ./temp/scripts/bignumber.js-9.1.1.js" -e "/importScripts(\"\.\.\/scripts\/bignumber\.js-9\.1\.1\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/common\.js\");/r ./temp/scripts/common.js" -e "/importScripts(\"\.\.\/scripts\/common\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/crypto\.js\");/r ./temp/scripts/crypto.js" -e "/importScripts(\"\.\.\/scripts\/crypto\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/identifier\.js\");/r ./temp/scripts/identifier.js" -e "/importScripts(\"\.\.\/scripts\/identifier\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/proof_builder\.js\");/r ./temp/scripts/proof_builder.js" -e "/importScripts(\"\.\.\/scripts\/proof_builder\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/legacy_proof_builder\.js\");/r ./temp/scripts/legacy_proof_builder.js" -e "/importScripts(\"\.\.\/scripts\/legacy_proof_builder\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/new_proof_builder\.js\");/r ./temp/scripts/new_proof_builder.js" -e "/importScripts(\"\.\.\/scripts\/new_proof_builder\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/view_proof_builder\.js\");/r ./temp/scripts/view_proof_builder.js" -e "/importScripts(\"\.\.\/scripts\/view_proof_builder\.js\");/d" "./temp/scripts/output_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/output\.js\");/r ./temp/scripts/output.js" -e "/importScripts(\"\.\.\/scripts\/output\.js\");/d" "./temp/scripts/output_worker.js"
sed -i "/--><script .*\".\/scripts\/output\.js\".*><!--/i --><script id=\"output_worker\" type=\"javascript\/worker\">" "./temp/index.html"
sed -i -e "/--><script .*\"output_worker\".*>/r ./temp/scripts/output_worker.js" -e "/--><script .*\"output_worker\".*>/a </script><!--" "./temp/index.html"
sed -i "s/Output\.WORKER_FILE_LOCATION/window[\"URL\"].createObjectURL(new Blob([document\.getElementById(\"output_worker\")[\"textContent\"]], {\"type\": \"application\/javascript\"}))/" "./temp/scripts/output.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/camera\.js\");/r ./temp/scripts/camera.js" -e "/importScripts(\"\.\.\/scripts\/camera\.js\");/d" "./temp/scripts/camera_worker.js"
sed -i -e "/importScripts(\"\.\.\/scripts\/jsQR-1\.4\.0\.js\");/r ./temp/scripts/jsQR-1.4.0.js" -e "/importScripts(\"\.\.\/scripts\/jsQR-1\.4\.0\.js\");/d" "./temp/scripts/camera_worker.js"
sed -i "/--><script .*\".\/scripts\/camera\.js\".*><!--/i --><script id=\"camera_worker\" type=\"javascript\/worker\">" "./temp/index.html"
sed -i -e "/--><script .*\"camera_worker\".*>/r ./temp/scripts/camera_worker.js" -e "/--><script .*\"camera_worker\".*>/a </script><!--" "./temp/index.html"
sed -i "s/Camera\.WORKER_FILE_LOCATION/window[\"URL\"].createObjectURL(new Blob([document\.getElementById(\"camera_worker\")[\"textContent\"]], {\"type\": \"application\/javascript\"}))/" "./temp/scripts/camera.js"
# Inline scripts
sed -i -e "/--><script .*\".\/scripts\/jQuery-3\.6\.4\.js\".*><!--/r ./temp/scripts/jQuery-3.6.4.js" -e "/--><script .*\".\/scripts\/jQuery-3\.6\.4\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/jQuery-3\.6\.4\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/jQuery-3\.6\.4\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/bignumber\.js-9\.1\.1\.js\".*><!--/r ./temp/scripts/bignumber.js-9.1.1.js" -e "/--><script .*\".\/scripts\/bignumber\.js-9\.1\.1\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/bignumber\.js-9\.1\.1\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/bignumber\.js-9\.1\.1\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/common\.js\".*><!--/r ./temp/scripts/common.js" -e "/--><script .*\".\/scripts\/common\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/common\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/common\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/consensus\.js\".*><!--/r ./temp/scripts/consensus.js" -e "/--><script .*\".\/scripts\/consensus\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/consensus\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/consensus\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/languages\.js\".*><!--/r ./temp/scripts/languages.js" -e "/--><script .*\".\/scripts\/languages\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/languages\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/languages\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/language\.js\".*><!--/r ./temp/scripts/language.js" -e "/--><script .*\".\/scripts\/language\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/language\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/language\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/extension\.js\".*><!--/r ./temp/scripts/extension.js" -e "/--><script .*\".\/scripts\/extension\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/extension\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/extension\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/JSONBigNumber-1\.1\.1\.js\".*><!--/r ./temp/scripts/JSONBigNumber-1.1.1.js" -e "/--><script .*\".\/scripts\/JSONBigNumber-1\.1\.1\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/JSONBigNumber-1\.1\.1\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/JSONBigNumber-1\.1\.1\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/glMatrix-3\.4\.1\.js\".*><!--/r ./temp/scripts/glMatrix-3.4.1.js" -e "/--><script .*\".\/scripts\/glMatrix-3\.4\.1\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/glMatrix-3\.4\.1\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/glMatrix-3\.4\.1\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/BLAKE2b-0\.0\.2\.js\".*><!--/r ./temp/scripts/BLAKE2b-0.0.2.js" -e "/--><script .*\".\/scripts\/BLAKE2b-0\.0\.2\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/BLAKE2b-0\.0\.2\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/BLAKE2b-0\.0\.2\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/Ed25519-0\.0\.22\.js\".*><!--/r ./temp/scripts/Ed25519-0.0.22.js" -e "/--><script .*\".\/scripts\/Ed25519-0\.0\.22\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/Ed25519-0\.0\.22\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/Ed25519-0\.0\.22\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/X25519-0\.0\.23\.js\".*><!--/r ./temp/scripts/X25519-0.0.23.js" -e "/--><script .*\".\/scripts\/X25519-0\.0\.23\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/X25519-0\.0\.23\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/X25519-0\.0\.23\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/js-sha3-0\.8\.0\.js\".*><!--/r ./temp/scripts/js-sha3-0.8.0.js" -e "/--><script .*\".\/scripts\/js-sha3-0\.8\.0\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/js-sha3-0\.8\.0\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/js-sha3-0\.8\.0\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/js-sha256-0\.10\.0\.js\".*><!--/r ./temp/scripts/js-sha256-0.10.0.js" -e "/--><script .*\".\/scripts\/js-sha256-0\.10\.0\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/js-sha256-0\.10\.0\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/js-sha256-0\.10\.0\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/ChaCha-2\.1\.0\.js\".*><!--/r ./temp/scripts/ChaCha-2.1.0.js" -e "/--><script .*\".\/scripts\/ChaCha-2\.1\.0\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/ChaCha-2\.1\.0\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/ChaCha-2\.1\.0\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/secp256k1-zkp-0\.0\.29\.js\".*><!--/r ./temp/scripts/secp256k1-zkp-0.0.29.js" -e "/--><script .*\".\/scripts\/secp256k1-zkp-0\.0\.29\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/secp256k1-zkp-0\.0\.29\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/secp256k1-zkp-0\.0\.29\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/SMAZ-0\.0\.31\.js\".*><!--/r ./temp/scripts/SMAZ-0.0.31.js" -e "/--><script .*\".\/scripts\/SMAZ-0\.0\.31\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/SMAZ-0\.0\.31\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/SMAZ-0\.0\.31\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hi-base32-0\.5\.1\.js\".*><!--/r ./temp/scripts/hi-base32-0.5.1.js" -e "/--><script .*\".\/scripts\/hi-base32-0\.5\.1\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hi-base32-0\.5\.1\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hi-base32-0\.5\.1\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/bech32-2\.0\.0\.js\".*><!--/r ./temp/scripts/bech32-2.0.0.js" -e "/--><script .*\".\/scripts\/bech32-2\.0\.0\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/bech32-2\.0\.0\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/bech32-2\.0\.0\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/base58\.js\".*><!--/r ./temp/scripts/base58.js" -e "/--><script .*\".\/scripts\/base58\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/base58\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/base58\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/base64\.js-3\.7\.5\.js\".*><!--/r ./temp/scripts/base64.js-3.7.5.js" -e "/--><script .*\".\/scripts\/base64\.js-3\.7\.5\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/base64\.js-3\.7\.5\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/base64\.js-3\.7\.5\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/crc32-1\.2\.0\.js\".*><!--/r ./temp/scripts/crc32-1.2.0.js" -e "/--><script .*\".\/scripts\/crc32-1\.2\.0\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/crc32-1\.2\.0\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/crc32-1\.2\.0\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/bit_reader\.js\".*><!--/r ./temp/scripts/bit_reader.js" -e "/--><script .*\".\/scripts\/bit_reader\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/bit_reader\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/bit_reader\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/bit_writer\.js\".*><!--/r ./temp/scripts/bit_writer.js" -e "/--><script .*\".\/scripts\/bit_writer\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/bit_writer\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/bit_writer\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/fatal_error\.js\".*><!--/r ./temp/scripts/fatal_error.js" -e "/--><script .*\".\/scripts\/fatal_error\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/fatal_error\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/fatal_error\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/startup_images_creator\.js\".*><!--/r ./temp/scripts/startup_images_creator.js" -e "/--><script .*\".\/scripts\/startup_images_creator\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/startup_images_creator\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/startup_images_creator\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/scroll\.js\".*><!--/r ./temp/scripts/scroll.js" -e "/--><script .*\".\/scripts\/scroll\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/scroll\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/scroll\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/copyright\.js\".*><!--/r ./temp/scripts/copyright.js" -e "/--><script .*\".\/scripts\/copyright\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/copyright\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/copyright\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/protocol_handler\.js\".*><!--/r ./temp/scripts/protocol_handler.js" -e "/--><script .*\".\/scripts\/protocol_handler\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/protocol_handler\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/protocol_handler\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/settings\.js\".*><!--/r ./temp/scripts/settings.js" -e "/--><script .*\".\/scripts\/settings\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/settings\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/settings\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/crypto\.js\".*><!--/r ./temp/scripts/crypto.js" -e "/--><script .*\".\/scripts\/crypto\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/crypto\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/crypto\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/json_rpc\.js\".*><!--/r ./temp/scripts/json_rpc.js" -e "/--><script .*\".\/scripts\/json_rpc\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/json_rpc\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/json_rpc\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/tor\.js\".*><!--/r ./temp/scripts/tor.js" -e "/--><script .*\".\/scripts\/tor\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/tor\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/tor\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/mqs\.js\".*><!--/r ./temp/scripts/mqs.js" -e "/--><script .*\".\/scripts\/mqs\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/mqs\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/mqs\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slatepack\.js\".*><!--/r ./temp/scripts/slatepack.js" -e "/--><script .*\".\/scripts\/slatepack\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slatepack\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slatepack\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/uuid\.js\".*><!--/r ./temp/scripts/uuid.js" -e "/--><script .*\".\/scripts\/uuid\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/uuid\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/uuid\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hash\.js\".*><!--/r ./temp/scripts/hash.js" -e "/--><script .*\".\/scripts\/hash\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hash\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hash\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slate\.js\".*><!--/r ./temp/scripts/slate.js" -e "/--><script .*\".\/scripts\/slate\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slate\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slate\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slate_participant\.js\".*><!--/r ./temp/scripts/slate_participant.js" -e "/--><script .*\".\/scripts\/slate_participant\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slate_participant\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slate_participant\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slate_input\.js\".*><!--/r ./temp/scripts/slate_input.js" -e "/--><script .*\".\/scripts\/slate_input\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slate_input\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slate_input\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slate_output\.js\".*><!--/r ./temp/scripts/slate_output.js" -e "/--><script .*\".\/scripts\/slate_output\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slate_output\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slate_output\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/slate_kernel\.js\".*><!--/r ./temp/scripts/slate_kernel.js" -e "/--><script .*\".\/scripts\/slate_kernel\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/slate_kernel\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/slate_kernel\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/proof_builder\.js\".*><!--/r ./temp/scripts/proof_builder.js" -e "/--><script .*\".\/scripts\/proof_builder\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/proof_builder\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/proof_builder\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/legacy_proof_builder\.js\".*><!--/r ./temp/scripts/legacy_proof_builder.js" -e "/--><script .*\".\/scripts\/legacy_proof_builder\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/legacy_proof_builder\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/legacy_proof_builder\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/new_proof_builder\.js\".*><!--/r ./temp/scripts/new_proof_builder.js" -e "/--><script .*\".\/scripts\/new_proof_builder\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/new_proof_builder\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/new_proof_builder\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/view_proof_builder\.js\".*><!--/r ./temp/scripts/view_proof_builder.js" -e "/--><script .*\".\/scripts\/view_proof_builder\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/view_proof_builder\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/view_proof_builder\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hardware_wallet\.js\".*><!--/r ./temp/scripts/hardware_wallet.js" -e "/--><script .*\".\/scripts\/hardware_wallet\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hardware_wallet\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hardware_wallet\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hardware_wallet_usb_transport\.js\".*><!--/r ./temp/scripts/hardware_wallet_usb_transport.js" -e "/--><script .*\".\/scripts\/hardware_wallet_usb_transport\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hardware_wallet_usb_transport\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hardware_wallet_usb_transport\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hardware_wallet_bluetooth_transport\.js\".*><!--/r ./temp/scripts/hardware_wallet_bluetooth_transport.js" -e "/--><script .*\".\/scripts\/hardware_wallet_bluetooth_transport\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hardware_wallet_bluetooth_transport\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hardware_wallet_bluetooth_transport\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/hardware_wallet_definitions\.js\".*><!--/r ./temp/scripts/hardware_wallet_definitions.js" -e "/--><script .*\".\/scripts\/hardware_wallet_definitions\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/hardware_wallet_definitions\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/hardware_wallet_definitions\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/protocol_buffers\.js\".*><!--/r ./temp/scripts/protocol_buffers.js" -e "/--><script .*\".\/scripts\/protocol_buffers\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/protocol_buffers\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/protocol_buffers\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/api\.js\".*><!--/r ./temp/scripts/api.js" -e "/--><script .*\".\/scripts\/api\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/api\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/api\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/instance\.js\".*><!--/r ./temp/scripts/instance.js" -e "/--><script .*\".\/scripts\/instance\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/instance\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/instance\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/service_worker_installer\.js\".*><!--/r ./temp/scripts/service_worker_installer.js" -e "/--><script .*\".\/scripts\/service_worker_installer\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/service_worker_installer\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/service_worker_installer\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/wallet\.js\".*><!--/r ./temp/scripts/wallet.js" -e "/--><script .*\".\/scripts\/wallet\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/wallet\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/wallet\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/identifier\.js\".*><!--/r ./temp/scripts/identifier.js" -e "/--><script .*\".\/scripts\/identifier\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/identifier\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/identifier\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/database_transaction\.js\".*><!--/r ./temp/scripts/database_transaction.js" -e "/--><script .*\".\/scripts\/database_transaction\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/database_transaction\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/database_transaction\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/database\.js\".*><!--/r ./temp/scripts/database.js" -e "/--><script .*\".\/scripts\/database\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/database\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/database\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/transaction\.js\".*><!--/r ./temp/scripts/transaction.js" -e "/--><script .*\".\/scripts\/transaction\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/transaction\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/transaction\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/transactions\.js\".*><!--/r ./temp/scripts/transactions.js" -e "/--><script .*\".\/scripts\/transactions\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/transactions\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/transactions\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/height\.js\".*><!--/r ./temp/scripts/height.js" -e "/--><script .*\".\/scripts\/height\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/height\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/height\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/initial_heights_obtained\.js\".*><!--/r ./temp/scripts/initial_heights_obtained.js" -e "/--><script .*\".\/scripts\/initial_heights_obtained\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/initial_heights_obtained\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/initial_heights_obtained\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/recent_heights\.js\".*><!--/r ./temp/scripts/recent_heights.js" -e "/--><script .*\".\/scripts\/recent_heights\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/recent_heights\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/recent_heights\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/output\.js\".*><!--/r ./temp/scripts/output.js" -e "/--><script .*\".\/scripts\/output\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/output\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/output\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/output_information\.js\".*><!--/r ./temp/scripts/output_information.js" -e "/--><script .*\".\/scripts\/output_information\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/output_information\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/output_information\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/tor_proxy\.js\".*><!--/r ./temp/scripts/tor_proxy.js" -e "/--><script .*\".\/scripts\/tor_proxy\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/tor_proxy\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/tor_proxy\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/node\.js\".*><!--/r ./temp/scripts/node.js" -e "/--><script .*\".\/scripts\/node\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/node\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/node\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/seed\.js\".*><!--/r ./temp/scripts/seed.js" -e "/--><script .*\".\/scripts\/seed\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/seed\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/seed\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/wallets\.js\".*><!--/r ./temp/scripts/wallets.js" -e "/--><script .*\".\/scripts\/wallets\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/wallets\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/wallets\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/listener\.js\".*><!--/r ./temp/scripts/listener.js" -e "/--><script .*\".\/scripts\/listener\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/listener\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/listener\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/interaction\.js\".*><!--/r ./temp/scripts/interaction.js" -e "/--><script .*\".\/scripts\/interaction\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/interaction\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/interaction\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/install_app\.js\".*><!--/r ./temp/scripts/install_app.js" -e "/--><script .*\".\/scripts\/install_app\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/install_app\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/install_app\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/focus\.js\".*><!--/r ./temp/scripts/focus.js" -e "/--><script .*\".\/scripts\/focus\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/focus\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/focus\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/caps_lock\.js\".*><!--/r ./temp/scripts/caps_lock.js" -e "/--><script .*\".\/scripts\/caps_lock\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/caps_lock\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/caps_lock\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/message\.js\".*><!--/r ./temp/scripts/message.js" -e "/--><script .*\".\/scripts\/message\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/message\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/message\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/prices\.js\".*><!--/r ./temp/scripts/prices.js" -e "/--><script .*\".\/scripts\/prices\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/prices\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/prices\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/log\.js\".*><!--/r ./temp/scripts/log.js" -e "/--><script .*\".\/scripts\/log\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/log\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/log\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/clipboard\.js\".*><!--/r ./temp/scripts/clipboard.js" -e "/--><script .*\".\/scripts\/clipboard\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/clipboard\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/clipboard\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/sections\.js\".*><!--/r ./temp/scripts/sections.js" -e "/--><script .*\".\/scripts\/sections\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/sections\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/sections\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/section\.js\".*><!--/r ./temp/scripts/section.js" -e "/--><script .*\".\/scripts\/section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/settings_section\.js\".*><!--/r ./temp/scripts/settings_section.js" -e "/--><script .*\".\/scripts\/settings_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/settings_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/settings_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/about_section\.js\".*><!--/r ./temp/scripts/about_section.js" -e "/--><script .*\".\/scripts\/about_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/about_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/about_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/transaction_section\.js\".*><!--/r ./temp/scripts/transaction_section.js" -e "/--><script .*\".\/scripts\/transaction_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/transaction_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/transaction_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/account_section\.js\".*><!--/r ./temp/scripts/account_section.js" -e "/--><script .*\".\/scripts\/account_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/account_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/account_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/wallet_section\.js\".*><!--/r ./temp/scripts/wallet_section.js" -e "/--><script .*\".\/scripts\/wallet_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/wallet_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/wallet_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/send_payment_section\.js\".*><!--/r ./temp/scripts/send_payment_section.js" -e "/--><script .*\".\/scripts\/send_payment_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/send_payment_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/send_payment_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/log_section\.js\".*><!--/r ./temp/scripts/log_section.js" -e "/--><script .*\".\/scripts\/log_section\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/log_section\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/log_section\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/unlocked\.js\".*><!--/r ./temp/scripts/unlocked.js" -e "/--><script .*\".\/scripts\/unlocked\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/unlocked\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/unlocked\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/version\.js\".*><!--/r ./temp/scripts/version.js" -e "/--><script .*\".\/scripts\/version\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/version\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/version\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/cookie_acceptance\.js\".*><!--/r ./temp/scripts/cookie_acceptance.js" -e "/--><script .*\".\/scripts\/cookie_acceptance\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/cookie_acceptance\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/cookie_acceptance\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/maintenance_notification\.js\".*><!--/r ./temp/scripts/maintenance_notification.js" -e "/--><script .*\".\/scripts\/maintenance_notification\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/maintenance_notification\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/maintenance_notification\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/tetris\.js\".*><!--/r ./temp/scripts/tetris.js" -e "/--><script .*\".\/scripts\/tetris\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/tetris\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/tetris\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/logo\.js\".*><!--/r ./temp/scripts/logo.js" -e "/--><script .*\".\/scripts\/logo\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/logo\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/logo\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/qrcode-generator-1\.4\.4\.js\".*><!--/r ./temp/scripts/qrcode-generator-1.4.4.js" -e "/--><script .*\".\/scripts\/qrcode-generator-1\.4\.4\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/qrcode-generator-1\.4\.4\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/qrcode-generator-1\.4\.4\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/automatic_lock\.js\".*><!--/r ./temp/scripts/automatic_lock.js" -e "/--><script .*\".\/scripts\/automatic_lock\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/automatic_lock\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/automatic_lock\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/wake_lock\.js\".*><!--/r ./temp/scripts/wake_lock.js" -e "/--><script .*\".\/scripts\/wake_lock\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/wake_lock\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/wake_lock\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/camera\.js\".*><!--/r ./temp/scripts/camera.js" -e "/--><script .*\".\/scripts\/camera\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/camera\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/camera\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/emoji\.js\".*><!--/r ./temp/scripts/emoji.js" -e "/--><script .*\".\/scripts\/emoji\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/emoji\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/emoji\.js\".*><!--/d" "./temp/index.html"
sed -i -e "/--><script .*\".\/scripts\/application\.js\".*><!--/r ./temp/scripts/application.js" -e "/--><script .*\".\/scripts\/application\.js\".*><!--/i --><script>" -e "/--><script .*\".\/scripts\/application\.js\".*><!--/a </script><!--" -e "/--><script .*\".\/scripts\/application\.js\".*><!--/d" "./temp/index.html"
# Get result
mv "./temp/index.html" "./MWC Wallet Standalone v$VERSION.html"
# Cleanup
rm -rf "./temp" "./master.zip" "./mwcwallet.com-master"