Fix build 5?

This commit is contained in:
Eric Fennis
2023-05-09 23:29:37 +02:00
parent a5e4c546c8
commit 44b602e6e4
4 changed files with 24 additions and 9 deletions
+1 -1
View File
@@ -118,7 +118,7 @@ If you'd prefer, you can use CSS to hold your base SVG properties
and update the SVG as follows
```svg
```xml
<svg
xmlns="http://www.w3.org/2000/svg"
class="lucide-icon"
+1 -5
View File
@@ -4,11 +4,7 @@ export default {
paths: async () => {
const icons = await getAllData()
return icons.map((iconData, index) => {
const params = {
...iconData,
};
return icons.map((params) => {
return {
params,
}
+8 -1
View File
@@ -2,5 +2,12 @@
"cleanUrls": true,
"github": {
"silent": true
}
},
"redirects": [
{
"source": "/icon/:path*",
"destination": "/icons/:path*",
"permanent": true
}
]
}
+14 -2
View File
@@ -1,3 +1,4 @@
/* eslint-disable no-restricted-syntax, no-await-in-loop */
import { CleanOptions, simpleGit } from 'simple-git';
import semver from 'semver';
import fs from 'fs';
@@ -66,12 +67,23 @@ const findRelease = (date, releases) => {
const fetchCommits = async (name) => {
const file = `../icons/${name}.svg`;
const { all: commits } = await simpleGit().log(['--reverse', '--follow', '--', file]);
const { all: commits = {} } = await simpleGit().log(['--reverse', '--follow', '--', file]);
return commits;
};
export const getReleaseMetadata = async (name, aliases, releases) => {
const metadata = { name };
const metadata = {
name,
createdRelease: {
version: '0.0.0',
date: new Date().toISOString(),
},
changedRelease: {
version: '0.0.0',
date: new Date().toISOString(),
},
};
for (const alias of [name, ...(aliases ?? [])]) {
const commits = await fetchCommits(alias);
for (const commit of commits) {