Skip to content

Commit

Permalink
fix: reproducible typescript output (#1159) (#1179)
Browse files Browse the repository at this point in the history
  • Loading branch information
rnm-sxm committed Jan 24, 2024
1 parent 2231f78 commit a11e821
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/orval/src/import-specs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ const resolveSpecs = async (

// normalizing slashes after SwaggerParser
return Object.fromEntries(
Object.entries(data).map(([key, value]) => [upath.resolve(key), value]),
Object.entries(data)
.sort()
.map(([key, value]) => [upath.resolve(key), value]),
);
} catch {
const file = await fs.readFile(path, 'utf8');
Expand Down

0 comments on commit a11e821

Please sign in to comment.