Skip to content

FrankerFaceZ/Extension

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FrankerFaceZ Build Script

Copyright (c) 2024 Dan Salvato LLC

Licensed under the Apache License, Version 2.0. See LICENSE.

The build process is intended to be performed using CI via GitHub Actions. However, the individual steps can be performed manually should you wish.

Requirements

  • node 18+
  • pnpm 8+
  • git

How to Build: Source Archive (Firefox Staff: Use This!)

These instructions assume you're starting with a prepared archive of the relevant source material. You can find such an archive by grabbing the source artifact from a run of our build process on GitHub. Additionally, we submit copies of the source artifact when uploading to Firefox due to Firefox's approval requirements.

  1. Ensure you have the requirements installed on your machine.
  2. Run this command to load the cached environmental variables with version info:
    source ffz_env
  3. Build the main client.
    cd client
    pnpm install
    pnpm build:ext
    cd ..
  4. Build the add-ons.
    cd addons
    pnpm install
    pnpm build:ext
    cd ..
  5. Ensure you don't have a dist folder. Delete it if you do with:
    rm -rf dist
  6. Copy the build output from steps 5 and 6 into the dist folder:
    chmod +x scripts/copy-output.sh
    ./scripts/copy-output.sh
  7. Update the version in the manifest.
    node scripts/update-manifest.js
  8. Find the unpacked extension in the dist folder.

That's it. You're done! You can now zip the extension, if you need to, or do anything else.

How to Build: Complete From Scratch (Firefox Staff: You don't need this!)

These instructions assume you're working from a clean checkout of the Extension repository itself, without any pre-downloaded source.

  1. Ensure you have the requirements installed on your machine.
  2. Run the following git commands to download the latest source code from FrankerFaceZ's repositories:
    git clone https://github.com/FrankerFaceZ/FrankerFaceZ.git client
    git clone https://github.com/FrankerFaceZ/Add-Ons.git addons
  3. Run these commands to calculate the correct version information based on the state of the git repositories:
    chmod +x scripts/calculate-version.sh
    ./scripts/calculate-version.sh
  4. Run this command to load the appropriate environmental variables:
    source ffz_env
  5. Build the main client.
    cd client
    pnpm install
    pnpm build:ext
    cd ..
  6. Build the add-ons.
    cd addons
    pnpm install
    pnpm build:ext
    cd ..
  7. Ensure you don't have a dist folder. Delete it if you do with:
    rm -rf dist
  8. Copy the build output from steps 5 and 6 into the dist folder:
    chmod +x scripts/copy-output.sh
    ./scripts/copy-output.sh
  9. Update the version in the manifest.
    node scripts/update-manifest.js
  10. Find the unpacked extension in the dist folder.

That's it. You're done! You can now zip the extension, if you need to, or do anything else.

About

Scripts for building the extension.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published