-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #35 from kamakiri01/add-image-download-log-parser
add image download log parser
- Loading branch information
Showing
7 changed files
with
38 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
# ChangeLog | ||
|
||
## 7.2.0 | ||
- 画像ダウンロードのログをパースできるよう変更 | ||
|
||
## 7.1.1 | ||
- `--import` オプション指定時にDB更新が二重に実行されていた問題を修正 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { ActivityLog, ActivityType } from "./common"; | ||
|
||
export interface ImageDownloadActivityLog extends ActivityLog { | ||
activityType: typeof ActivityType.ImageDownload; | ||
url: string; | ||
} |
12 changes: 12 additions & 0 deletions
12
src/util/parseVRChatLog/activityLogGenerator/imageDownload.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { ActivityType } from "../../.."; | ||
import { ImageDownloadActivityLog } from "../../../type/activityLogType/imageDownloadType"; | ||
|
||
export function createImageDownloadActivityLog(utcTime: number, message: string): ImageDownloadActivityLog { | ||
const reg = /\[Image Download\] Attempting to load image from URL '(.+)'/.exec(message)!; | ||
const activity: ImageDownloadActivityLog = { | ||
date: utcTime, | ||
activityType: ActivityType.ImageDownload, | ||
url: reg[1], | ||
}; | ||
return activity; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters