火狐怎么导入旧的火狐数据
Take a few moments with me to learn how to build the amazing Firefox!
花点时间与我一起学习如何构建出色的Firefox!
步骤1:克隆Mozilla Central (Step 1: Clone Mozilla Central)
is the name of the mercurial repository that contains the source code of Firefox. Start by installing mercurial and cloning "MC":
是包含Firefox源代码的Mercurial存储库的名称。 首先安装Mercurial并克隆“ MC”:
hg clone https://hg.mozilla.org/mozilla-central/
hg clone {repo_url}
is the first and most basic mercurial command, but check out my post to learn more hg
commands! "MC" will be installed in a mozilla-central
directory.
hg clone {repo_url}
是第一个也是最基本的水银命令,但请查看我的帖子以了解更多hg
命令! “ MC”将安装在mozilla-central
目录中。
步骤2:安装依赖项 (Step 2: Install Dependencies)
From C++ to Rust, Firefox has a fair bit of requirements you'll need to install. From within the mozilla-central
directory, run the following:
从C ++到Rust,Firefox需要安装很多需求。 在mozilla-central
目录中,运行以下命令:
./mach bootstrap
The bootstrap
command will install dependencies as well as configure mercurial extensions as required. Congratulations -- you're now ready to build!
bootstrap
命令将安装依赖项,并根据需要配置商业扩展。 恭喜您,您现在可以开始构建了!
步骤3:建立mozconfig (Step 3: Create a mozconfig)
You'll thank me for this one! Create a mozconfig
file to use , which will save loads of time during the build process by downloading pre-built binaries for Firefox's internals.
您会感谢我的! 创建一个mozconfig
文件以使用 ,这将通过下载Firefox内部的预构建二进制文件来节省构建过程中的时间。
# Automatically download and use compiled C++ components:ac_add_options --enable-artifact-builds# Write build artifacts to:mk_add_options MOZ_OBJDIR=./objdir-frontend
Place the code above in your mozconfig
file and you're builds will be super fast!
将上面的代码放在您的mozconfig
文件中,您的构建将非常快捷!
步骤4:建立! (Step 4: Build!)
Once you have the code and the dependencies, it's time to build the amazing Firefox! You can build Firefox with the following command:
一旦有了代码和依赖项,就可以构建出色的Firefox! 您可以使用以下命令构建Firefox:
./mach build
Hello Firefox!
您好,Firefox!
步骤5:运行Firefox (Step 5: Run Firefox)
Once you've built the amazing Firefox, you can run Firefox with the following mach
command:
构建出色的Firefox之后,可以使用以下mach
命令运行Firefox:
./mach run --jsdebugger
Congratulations! You've taken the Firefox source code and turned it into an application that you can run! The --jsdebugger
option opens the "browser toolbox" which allows you to debug the Firefox you've just built.
恭喜你! 您已经获取了Firefox源代码,并将其转换为可以运行的应用程序! --jsdebugger
选项打开“浏览器工具箱”,它使您可以调试刚刚构建的Firefox。
更新Mozilla中央代码 (Updating Mozilla Central Code)
The Mozilla Central repository is updated several times a day as Mozilla employees and contributors like you submit patches. You can update your local checkout with the following:
Mozilla中央存储库每天都会更新几次,因为Mozilla的员工和像您一样的贡献者都提交了补丁。 您可以使用以下内容更新本地结帐:
hg pull && hg update --clean
You local commits will always be draft
status while patches which have been merged into MC will be public
status.
您的本地提交将始终为draft
状态,而已合并到MC中的补丁将为public
状态。
配置选项 (Configuring Options)
Whenever Firefox developer and the community develop new features, they're hidden behind a preference until the feature reaches maturity. To toggle feature flags, you can visit about:config
in your local Firefox or any Firefox release.
每当Firefox开发人员和社区开发新功能时,它们都会隐藏在首选项后面,直到该功能成熟为止。 要切换功能标志,您可以在本地Firefox或任何Firefox版本中访问about:config
。
The config page allows you to toggle and set a number of options. Many "edge" features debut behind feature flags in Firefox Nightly.
配置页面允许您切换和设置许多选项。 在Firefox Nightly中,许多“边缘”功能首次出现在功能标记后面。
Congratulations! You've turned a massive repository of code into a living, breathing Firefox web browser! In the next post in the Firefox series, we'll explore contribution and testing!
恭喜你! 您已经将庞大的代码库变成了可以呼吸的生动的Firefox Web浏览器! 在Firefox系列的下一篇文章中,我们将探讨贡献和测试!
翻译自:
火狐怎么导入旧的火狐数据