Skip to content

fix api docs download path #7560

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

Merged
merged 4 commits into from
Jun 17, 2025
Merged
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
5 changes: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ jobs:
if: ${{ matrix.generate_api_docs }}
uses: actions/upload-artifact@v4
with:
name: api-docs
name: api
path: scripts/res/apiDocs/

pkg-pr-new:
Expand Down Expand Up @@ -495,11 +495,12 @@ jobs:
uses: actions/download-artifact@v4
with:
artifact-ids: ${{ needs.build-compiler.outputs.api-docs-artifact-id }}
path: data/api
path: data

- name: Check if repo is clean
id: diffcheck
run: |
git status
if [ -z "$(git status --porcelain)" ]; then
echo "clean=true" >> $GITHUB_OUTPUT
else
Expand Down
8 changes: 2 additions & 6 deletions runtime/Stdlib_Array.resi
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ type t<'a> = array<'a>
type arrayLike<'a>

/**
`fromIterator(iterator)`

Creates an array from the provided `iterator`
`fromIterator(iterator)` creates an array from the provided `iterator`

## Examples

Expand All @@ -35,9 +33,7 @@ external fromIterator: Stdlib_Iterator.t<'a> => array<'a> = "Array.from"
external fromArrayLikeWithMap: (arrayLike<'a>, 'a => 'b) => array<'b> = "Array.from"

/**
`make(~length, init)`

Creates an array of length `length` initialized with the value of `init`.
`make(~length, init)` creates an array of length `length` initialized with the value of `init`.

## Examples

Expand Down
6 changes: 3 additions & 3 deletions tests/analysis_tests/tests/src/expected/Completion.res.txt
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ Path Array.
"kind": 12,
"tags": [],
"detail": "(~length: int, 'a) => array<'a>",
"documentation": {"kind": "markdown", "value": "\n`make(~length, init)`\n\nCreates an array of length `length` initialized with the value of `init`.\n\n## Examples\n\n```rescript\nArray.make(~length=3, #apple)->assertEqual([#apple, #apple, #apple])\nArray.make(~length=6, 7)->assertEqual([7, 7, 7, 7, 7, 7])\n```\n"}
"documentation": {"kind": "markdown", "value": "\n`make(~length, init)` creates an array of length `length` initialized with the value of `init`.\n\n## Examples\n\n```rescript\nArray.make(~length=3, #apple)->assertEqual([#apple, #apple, #apple])\nArray.make(~length=6, 7)->assertEqual([7, 7, 7, 7, 7, 7])\n```\n"}
}, {
"label": "lastIndexOfFrom",
"kind": 12,
Expand Down Expand Up @@ -573,7 +573,7 @@ Path Array.
"kind": 12,
"tags": [],
"detail": "Iterator.t<'a> => array<'a>",
"documentation": {"kind": "markdown", "value": "\n`fromIterator(iterator)`\n\nCreates an array from the provided `iterator`\n\n## Examples\n\n```rescript\nMap.fromArray([(\"foo\", 1), (\"bar\", 2)])\n->Map.values\n->Array.fromIterator\n->assertEqual([1, 2])\n```\n"}
"documentation": {"kind": "markdown", "value": "\n`fromIterator(iterator)` creates an array from the provided `iterator`\n\n## Examples\n\n```rescript\nMap.fromArray([(\"foo\", 1), (\"bar\", 2)])\n->Map.values\n->Array.fromIterator\n->assertEqual([1, 2])\n```\n"}
}, {
"label": "forEach",
"kind": 12,
Expand Down Expand Up @@ -613,7 +613,7 @@ Path Array.m
"kind": 12,
"tags": [],
"detail": "(~length: int, 'a) => array<'a>",
"documentation": {"kind": "markdown", "value": "\n`make(~length, init)`\n\nCreates an array of length `length` initialized with the value of `init`.\n\n## Examples\n\n```rescript\nArray.make(~length=3, #apple)->assertEqual([#apple, #apple, #apple])\nArray.make(~length=6, 7)->assertEqual([7, 7, 7, 7, 7, 7])\n```\n"}
"documentation": {"kind": "markdown", "value": "\n`make(~length, init)` creates an array of length `length` initialized with the value of `init`.\n\n## Examples\n\n```rescript\nArray.make(~length=3, #apple)->assertEqual([#apple, #apple, #apple])\nArray.make(~length=6, 7)->assertEqual([7, 7, 7, 7, 7, 7])\n```\n"}
}, {
"label": "map",
"kind": 12,
Expand Down
7 changes: 5 additions & 2 deletions yarn.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,17 @@ async function enforceCompilerMeta({ Yarn }) {
if (process.argv.includes("--fix")) {
await fs.writeFile(
compilerVersionFile,
versionFile.replace(versionPattern, `let version = "${EXPECTED_VERSION}"`)
versionFile.replace(
versionPattern,
`let version = "${EXPECTED_VERSION}"`,
),
);
} else {
const versionMatch = versionFile.match(versionPattern);
const foundVersion = versionMatch?.groups?.version;
if (foundVersion !== EXPECTED_VERSION) {
Yarn.workspace().error(
`compiler/common/bs_version.ml file need to be fixed; expected ${EXPECTED_VERSION}, found ${foundVersion}.`
`compiler/common/bs_version.ml file need to be fixed; expected ${EXPECTED_VERSION}, found ${foundVersion}.`,
);
}
}
Expand Down