Skip to content

Commit

Permalink
fix: rename
Browse files Browse the repository at this point in the history
  • Loading branch information
snomiao committed Jan 27, 2022
1 parent e79c1e1 commit 4dd254d
Show file tree
Hide file tree
Showing 4 changed files with 9,462 additions and 9,399 deletions.
15 changes: 0 additions & 15 deletions builder/bookmarks.mjs

This file was deleted.

14 changes: 13 additions & 1 deletion builder/greasyfork.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,16 @@ const sinfo = await pmap(
);

sinfo.map((e) => console.log(e.url));
await promisify(exec)('https://greasyfork.org/en/import');

const ss = sinfo
.map(
({ filename, mincode, url }) =>
// `[${filename}](javascript:${encodeURIComponent(mincode)})`
// `<a href='javascript:${mincode.replace(/'/g,'&apos;')}'>${filename}</a>`
// `${filename} - ${mincode}`
`<a href="javascript:(function(){document.body.appendChild(Object.assign(document.createElement('script'), {src: '${url}'}))}())">${filename}</a>`
)
.join('\n');
await fs.writeFile('./bookmarks/x.md', ss);

// await promisify(exec)('chrome https://greasyfork.org/en/import');

0 comments on commit 4dd254d

Please sign in to comment.