Skip to content

arrow2nd/line2json

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

line2json

LINE で出力したトーク履歴ファイルを JSON にパースするモジュール

使い方

パースする

import { parse, TalkData } from "https://deno.land/x/line2json@v0.1.0/mod.ts";

const text = Deno.readTextFileSync("talk_histroy.txt");
const histories: TalkData[] = parse(text);

console.log(histories);

JSON にする

import { toJson } from "https://deno.land/x/line2json@v0.1.0/mod.ts";

const text = Deno.readTextFileSync("talk_histroy.txt");
const json = toJson(text);

Deno.writeTextFileSync("histroy.json", json);

検証環境

  • Windows / Mac 版 LINE v7.2.0
  • Android 版 LINE v11.17.1

仕様

  • LINE のシステムメッセージや URL、LINE 依存の絵文字を含むメッセージは除外されます
  • 時刻は全て 24 時間表記です

About

💬 LINE のトーク履歴をパースする Deno モジュール

Topics

Resources

License

Stars

Watchers

Forks