Skip to content

Commit

Permalink
update sway (#442)
Browse files Browse the repository at this point in the history
  • Loading branch information
calldelegation authored Sep 27, 2024
1 parent 8f08d93 commit 69b019e
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion docs/builds/sway
Submodule sway updated 5278 files
2 changes: 1 addition & 1 deletion docs/nightly/builds/sway
Submodule sway updated 1658 files
2 changes: 1 addition & 1 deletion docs/nightly/sway
Submodule sway updated 278 files
2 changes: 1 addition & 1 deletion docs/sway
Submodule sway updated 443 files
9 changes: 4 additions & 5 deletions scripts/update-nightly/versions.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@ export async function getNightlyVersions() {
}

function getForcVersion(isNightly) {
const forcfiledir = `docs${
isNightly ? '/nightly' : ''
}/sway/forc-pkg/Cargo.toml`;
const forcfile = fs.readFileSync(forcfiledir, 'utf-8');
const version = forcfile?.match(/version = "(.*)"/)?.[1];
const forcfiledir = `docs${isNightly ? '/nightly' : ''}/sway/Cargo.toml`;
const forcfileContent = fs.readFileSync(forcfiledir, 'utf-8');
const forcfile = toml.parse(forcfileContent);
const version = forcfile.workspace.package.version;
return version;
}

Expand Down
2 changes: 1 addition & 1 deletion src/config/versions.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"default": {
"forc": "0.63.1",
"forc": "0.64.0",
"rust": "0.66.2",
"ts": "0.94.2",
"wallet": "0.25.0",
Expand Down
9 changes: 5 additions & 4 deletions src/lib/versions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@ export function getRustSDKVersion(docsDir: string) {
}

function getForcVersion(docsDir: string) {
const forcfiledir = join(docsDir, 'sway/forc-pkg/Cargo.toml');
const forcfile = fs.readFileSync(forcfiledir, 'utf-8');
const version = forcfile?.match(/version = "(.*)"/)?.[1];
const forcfiledir = join(docsDir, 'sway/Cargo.toml');
const forcfileContent = fs.readFileSync(forcfiledir, 'utf-8');
const forcfile = toml.parse(forcfileContent);
const version = forcfile.workspace.package.version;

return {
name: 'forc',
Expand Down Expand Up @@ -135,7 +136,7 @@ export function getVersions(versionSet: VersionSet) {
'Fuel Wallet': wallet,
'GraphQL API': fuelCore,
'Sway Standards': swayStandards,
'Sway Libraries': swayLibraries
'Sway Libraries': swayLibraries,
};
}

Expand Down

0 comments on commit 69b019e

Please sign in to comment.