Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add ci for docs-hub #104

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Docs

on:
push:
branches:
- master
pull_request:
release:
types: [published]

jobs:
test:
uses: FuelLabs/github-actions/.github/workflows/mdbook-docs.yml@master
with:
docs-src-path: 'book/src'
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ Each night at midnight (UTC) this repo is automatically updated with the latest
stable and nightly releases of all fuel packages. Builds are tested and cached
for `x86_64-linux`, `x86_64-darwin` and `aarch64-darwin` systems.

See the [**Quick Start**][fuel-nix-quick-start] guide from
See the [**Quickstart**][fuel-nix-quickstart] guide from
[**the book**][fuel-nix-book] to get started.

[fuel-nix-book]: https://nix.fuel.network
[fuel-nix-quick-start]: https://nix.fuel.network/quick-start
[fuel-nix-book]: https://docs.fuel.network
[fuel-nix-quickstart]: https://docs.fuel.network
10 changes: 5 additions & 5 deletions book/src/SUMMARY.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# Summary

- [Welcome](./welcome.md)
- [Quick Start](./quick-start.md)
- [Welcome](./index.md)
- [Quickstart](./quickstart.md)
- [Nix Setup](./nix-setup.md)
- [Packages](./packages.md)
- [Nix Power Users](./nix-power-users.md)
- [Nix Power Users](./nix-power-users/index.md)
- [Dev Shells](./nix-power-users/dev-shells.md)
- [Overlays](./nix-power-users/overlays.md)
- [Editor Plugins](./nix-power-users/editor-plugins.md)
- [Contributing](./contributing.md)
- [Internals](./contributing/internals.md)
- [Contributing](./contributing/index.md)
- [Internals](./contributing/internals/index.md)
- [Generating Manifests](./contributing/internals/generating-manifests.md)
- [Providing Packages](./contributing/internals/providing-packages.md)
- [Providing Milestones](./contributing/internals/providing-milestones.md)
Expand Down
4 changes: 2 additions & 2 deletions book/src/contributing/adding-packages.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ We can do so by adding a condition to the list of filters:
```

See the [Filtering
Manifests](./internals/providing-packages.html#filtering-manifests) section for
Manifests](./internals/providing-packages.md#filtering-manifests) section for
more details.

## Updating `./patches.nix`
Expand All @@ -95,7 +95,7 @@ unique attributes, environment variables, etc:
```

For more details on how to apply manifest patches, see the
[Patching Manifests](./internals/providing-packages.html#patching-manifests)
[Patching Manifests](./internals/providing-packages.md#patching-manifests)
section.

> **Tip:** Check the new package's upstream CI to get an idea of what system
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion book/src/contributing/internals/generating-manifests.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ to run.
The script begins by declaring all FuelLabs repositories that we care about,
followed by each unique package and which repository it is associated with.
To declare new packages, see the
[Adding Packages](./contributing/adding-packages.html) chapter.
[Adding Packages](../adding-packages.md) chapter.

The script aims to be idempotent, i.e. even if you were to delete the entire
`./manifests` directory and all its manifests, running the script again should
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

At a very high level, **fuel.nix** does the following:

1. [**Generate unique "manifests" for each version of each package**](./internals/generating-manifests.html)
1. [**Generate unique "manifests" for each version of each package**](./generating-manifests.md)
every night at 00:00 UTC under the `./manifests` directory using a CI action
that runs the `./scripts/refresh-manifests.sh` script.
2. [**Provide `package` flake outputs**](./internals/providing-packages.html)
2. [**Provide `package` flake outputs**](./providing-packages.md)
(e.g. `forc-0-20-0`, `fuel-core-0-18-0-nightly-2023-04-29`) by collecting,
filtering (`filters.nix`) and patching (`patches.nix`) all manifests. Also
provide package **sets** for the latest semver releases and nightlies e.g.
(`fuel-latest`, `fuel-nightly`).
3. [**Provide a special set of "milestone" packages**](./internals/providing-milestones.html)
3. [**Provide a special set of "milestone" packages**](./providing-milestones.md)
(e.g. `forc-wallet-beta-2`) and package sets (e.g. `fuel-beta-3`) by finding
packages that match the commits specified in `milestones.nix`.
4. **Provide `devShell`s** to assist working on the fuel repos by collecting all
Expand All @@ -21,6 +21,6 @@ Click on the links above to dive into more details on each step.

Alternatively, for a quick look at adding or updating packages:

- [**Adding Packages**](./adding-packages.html)
- [**Updating Packages**](./updating-packages.html)
- [**Updating Flake Inputs**](./updating-flake-inputs.html)
- [Adding Packages](../adding-packages.md)
- [Updating Packages](../updating-packages.md)
- [Updating Flake Inputs](../updating-flake-inputs.md)
98 changes: 49 additions & 49 deletions book/src/contributing/internals/providing-milestones.md
Original file line number Diff line number Diff line change
@@ -1,49 +1,49 @@
# Providing Milestones

**fuel.nix** allows for declaring "milestones".

Milestones provide a way of pinning a significant set of hand-picked commits
across the Fuel ecosystem under a single named release.

Milestones are provided by the `./milestones.nix` file. As of writing this,
the file includes milestones for `beta-1`, `beta-2` and `beta-3`.

Each milestone is a mapping from a name to a set of repository commits, each of
which is used to select the set of package manifests used to generate package
outputs for the milestone.

Here's what the `beta-2` milestone looks like:

```nix
beta-2 = {
forc-explorer = "4bb7392eed085ee3a6795b98ea25392b3f41ade8";
forc-wallet = "9473052e88048f58e8c4e1eba0ff88ef6a4cdd59";
fuel-core = "49e4305fea691bbf293c606334e7b282a54393b3";
fuel-indexer = "c2425c8b63f01ef1b540ff3e5832ebdc018b951d";
sway = "c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2";
};
```

While [providing packages](./providing-packages.html), milestones are used to
provide a unique output for each package along with a dedicated package set.
E.g. the above `beta-2` milestone is used to provide `fuel-core-beta-2` and
`forc-beta-2` package aliases, as well as the extra `fuel-beta-2` package set.

# Adding milestones

### Choosing Commits

When selecting commits from each repository for a new milestone, it can be
a good idea to do so from the top-down. I.e. First select a commit for the
Sway repo, then select commits for repos with dependencies (e.g. fuel-core)
by checking the versions that are tested under the Sway commit's integration
testing.

### CI

To ensure we maintain availability of milestone binaries in the cache, we build
each of the milestones under the CI workflow.

Currently, the milestones are manually specified. As a result, they'll need
to be updated upon adding new milestones, or removed when they're no longer
officially supported.
# Providing Milestones
**fuel.nix** allows for declaring "milestones".
Milestones provide a way of pinning a significant set of hand-picked commits
across the Fuel ecosystem under a single named release.
Milestones are provided by the `./milestones.nix` file. As of writing this,
the file includes milestones for `beta-1`, `beta-2` and `beta-3`.
Each milestone is a mapping from a name to a set of repository commits, each of
which is used to select the set of package manifests used to generate package
outputs for the milestone.
Here's what the `beta-2` milestone looks like:
```nix
beta-2 = {
forc-explorer = "4bb7392eed085ee3a6795b98ea25392b3f41ade8";
forc-wallet = "9473052e88048f58e8c4e1eba0ff88ef6a4cdd59";
fuel-core = "49e4305fea691bbf293c606334e7b282a54393b3";
fuel-indexer = "c2425c8b63f01ef1b540ff3e5832ebdc018b951d";
sway = "c32b0759d25c0b515cbf535f9fb9b8e6fda38ff2";
};
```
While [providing packages](./providing-packages.md), milestones are used to
provide a unique output for each package along with a dedicated package set.
E.g. the above `beta-2` milestone is used to provide `fuel-core-beta-2` and
`forc-beta-2` package aliases, as well as the extra `fuel-beta-2` package set.
## Adding milestones
### Choosing Commits
When selecting commits from each repository for a new milestone, it can be
a good idea to do so from the top-down. I.e. First select a commit for the
Sway repo, then select commits for repos with dependencies (e.g. fuel-core)
by checking the versions that are tested under the Sway commit's integration
testing.
### CI
To ensure we maintain availability of milestone binaries in the cache, we build
each of the milestones under the CI workflow.
Currently, the milestones are manually specified. As a result, they'll need
to be updated upon adding new milestones, or removed when they're no longer
officially supported.
Loading
Loading