mirror of
https://github.com/ThatGuySam/doesitarm.git
synced 2026-05-18 06:44:46 -07:00
Merge branch 'develop'
This commit is contained in:
commit
5360e5589e
3 changed files with 32 additions and 1 deletions
8
.vscode/tasks.json
vendored
8
.vscode/tasks.json
vendored
|
|
@ -15,6 +15,14 @@
|
|||
"problemMatcher": [],
|
||||
"label": "npm: generate",
|
||||
"detail": "nuxt generate",
|
||||
"group": "build"
|
||||
},
|
||||
{
|
||||
"type": "npm",
|
||||
"script": "generate-dev",
|
||||
"problemMatcher": [],
|
||||
"label": "npm: generate-dev",
|
||||
"detail": "npm run generate && npm test",
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": true
|
||||
|
|
|
|||
|
|
@ -283,6 +283,8 @@ export default async function () {
|
|||
|
||||
let bundleId = null
|
||||
let tags = []
|
||||
let aliases = []
|
||||
const relatedLinksMap = new Map( getTokenLinks(token.children).map( link => [ link.href, link ] ) )
|
||||
|
||||
// Search for this app in the scanList and remove duplicates
|
||||
scanListMap.forEach( ( scannedApp, key ) => {
|
||||
|
|
@ -301,13 +303,32 @@ export default async function () {
|
|||
...scannedApp.tags
|
||||
]))
|
||||
|
||||
// Merge as set then convert to array to prevent duplicates
|
||||
aliases = Array.from(new Set([
|
||||
...aliases,
|
||||
...scannedApp.aliases
|
||||
]))
|
||||
|
||||
// Merge relatated links
|
||||
for ( const link of scannedApp.relatedLinks ) {
|
||||
|
||||
relatedLinksMap.set( link.href, {
|
||||
...link,
|
||||
label: (link.label === 'View') ? 'App Website' : link.label
|
||||
} )
|
||||
}
|
||||
|
||||
console.log(`Merged ${alias} (${scannedApp.bundleId}) from scanned apps into ${name} from README`)
|
||||
scanListMap.delete( key )
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
const relatedLinks = getTokenLinks(token.children)
|
||||
|
||||
// Convert link map values into array for JSON
|
||||
const relatedLinks = Array.from( relatedLinksMap.values() )
|
||||
|
||||
// console.log('relatedLinks', relatedLinks)
|
||||
|
||||
const appSlug = makeSlug( name )
|
||||
|
||||
|
|
@ -342,6 +363,7 @@ export default async function () {
|
|||
|
||||
appList.push({
|
||||
name,
|
||||
aliases,
|
||||
status,
|
||||
bundleId,
|
||||
lastUpdated,
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@
|
|||
"dev": "nuxt",
|
||||
"build": "nuxt build",
|
||||
"start": "nuxt start",
|
||||
"generate-dev": "npm run generate && npm test",
|
||||
"generate": "npm run clone-readme && npm run build-lists && npm run generate-nuxt && npm run generate-eleventy",
|
||||
"build-lists": "node -r esm build-lists.js",
|
||||
"generate-nuxt": "NODE_OPTIONS=--max-old-space-size=60000 nuxt generate",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue