@travetto/manifest 4.0.2 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/module.ts +2 -1
- package/src/types/manifest.ts +3 -1
package/package.json
CHANGED
package/src/module.ts
CHANGED
|
@@ -184,7 +184,8 @@ export class ManifestModuleUtil {
|
|
|
184
184
|
* Convert file (by ext) to a known file type and also retrieve its latest timestamp
|
|
185
185
|
*/
|
|
186
186
|
static async transformFile(moduleFile: string, full: string): Promise<ManifestModuleFile> {
|
|
187
|
-
const
|
|
187
|
+
const updated = this.#getNewest(await fs.stat(full).catch(() => ({ mtimeMs: 0, ctimeMs: 0 })));
|
|
188
|
+
const res: ManifestModuleFile = [moduleFile, this.getFileType(moduleFile), updated];
|
|
188
189
|
const role = this.getFileRole(moduleFile);
|
|
189
190
|
return role ? [...res, role] : res;
|
|
190
191
|
}
|
package/src/types/manifest.ts
CHANGED
|
@@ -2,7 +2,9 @@ import type { ManifestModuleFileType, ManifestModuleFolderType, ManifestModuleRo
|
|
|
2
2
|
import type { ManifestContext } from './context';
|
|
3
3
|
import { Package } from './package';
|
|
4
4
|
|
|
5
|
-
export type ManifestModuleFile =
|
|
5
|
+
export type ManifestModuleFile =
|
|
6
|
+
[path: string, type: ManifestModuleFileType, updated: number] |
|
|
7
|
+
[path: string, type: ManifestModuleFileType, updated: number, role: ManifestModuleRole];
|
|
6
8
|
|
|
7
9
|
export type ManifestDepCore = {
|
|
8
10
|
/** Package name */
|