Skip to content

Commit 3073b4b

Browse files
committed
feat: add source_totals
1 parent eaf831b commit 3073b4b

File tree

7 files changed

+114
-150
lines changed

7 files changed

+114
-150
lines changed

packages/novel-epub/lib/epub.js

Lines changed: 23 additions & 44 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/novel-epub/lib/epub.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import { toFullWidth } from 'str-util';
1616
import Bluebird from 'bluebird';
1717
import path from 'upath2';
1818
import fs from 'fs-iconv';
19-
import * as novelGlobby from 'node-novel-globby/g';
19+
import { globby } from 'node-novel-globby/g';
2020
import { console } from './log';
2121

2222
export const SymCache = Symbol('cache');
@@ -106,7 +106,7 @@ export function _handleVolume(volume: IEpubMakerSectionWithCache, dirname: strin
106106

107107
//console.log(file, meta);
108108

109-
await Bluebird.resolve(novelGlobby.globby([
109+
await Bluebird.resolve(globby([
110110
'cover.*',
111111
], {
112112
cwd: dirname,
@@ -386,7 +386,7 @@ export function _handleVolumeImage(volume: IEpubMakerSectionWithCache | EpubMake
386386

387387
volume[SymCache].image = true;
388388

389-
return novelGlobby.globby(globImages, {
389+
return globby(globImages, {
390390
cwd: dirname,
391391
absolute: true,
392392
})
@@ -619,7 +619,7 @@ export function addContributeSection(volume: IEpubMakerSectionWithCache, dirname
619619

620620
volume[SymCache].contribute = false;
621621

622-
return novelGlobby.globby([
622+
return globby([
623623
'CONTRIBUTE.md',
624624
], {
625625
cwd: dirname,

packages/novel-epub/lib/ext.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export function toGlobExtImage()
2525
`images/*.{${exts}}`,
2626
`img/*.{${exts}}`,
2727
`imgs/*.{${exts}}`,
28-
]
28+
] as const
2929
}
3030

3131
export function isAllowExtImage(ext: string)

0 commit comments

Comments
 (0)