{"id":22548275,"url":"https://github.com/ewilan-riviere/scanner","last_synced_at":"2025-03-28T09:13:27.082Z","repository":{"id":207423476,"uuid":"719213272","full_name":"ewilan-riviere/scanner","owner":"ewilan-riviere","description":"CLI to parse files or to get metadata.","archived":false,"fork":false,"pushed_at":"2023-11-25T15:41:22.000Z","size":1929,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-02T09:43:22.055Z","etag":null,"topics":["filesystem","go","metadata","parser"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/ewilan-riviere/scanner","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ewilan-riviere.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-11-15T17:39:58.000Z","updated_at":"2024-12-15T04:48:57.000Z","dependencies_parsed_at":"2023-11-18T13:29:31.435Z","dependency_job_id":"da3df1e5-a029-42f4-acbe-3abb31cc1139","html_url":"https://github.com/ewilan-riviere/scanner","commit_stats":null,"previous_names":["ewilan-riviere/files"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewilan-riviere%2Fscanner","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewilan-riviere%2Fscanner/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewilan-riviere%2Fscanner/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewilan-riviere%2Fscanner/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ewilan-riviere","download_url":"https://codeload.github.com/ewilan-riviere/scanner/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245999602,"owners_count":20707570,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["filesystem","go","metadata","parser"],"created_at":"2024-12-07T15:14:53.542Z","updated_at":"2025-03-28T09:13:27.057Z","avatar_url":"https://github.com/ewilan-riviere.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# scanner\n\n[![go][go-version-src]][go-version-href]\n[![tests][tests-src]][tests-href]\n[![license][license-src]][license-href]\n\nCLI to parse files or to get metadata. Powered by Go.\n\nMetadata parsed by [`mediainfo`](https://mediaarea.net/en/MediaInfo) (v23.10).\n\n## Install\n\n```bash\ngo install github.com/ewilan-riviere/scanner@latest\n```\n\nYou have to install [`mediainfo`](https://mediaarea.net/en/MediaInfo) with `brew`, `apt` or `scoop` if you want to use `metadata` command.\n\n## Usage\n\n### Parse\n\nParse files from a path\n\n```bash\nscanner parse /path/to/directory\n```\n\nOptions:\n\n- `-o|--output`: output file path, if not set, output is printed in stdout\n- `-j|--json`: output is printed in json format\n\nOutput example\n\n```bash\n.gitignore\nLICENSE\nREADME.md\ngo.mod\ngo.sum\nmain.go\nmain_test.go\npkg/files/files.go\npkg/mediainfo/convert/convert.go\npkg/mediainfo/mediainfo.go\npkg/mediainfo/output/output.go\npkg/mediainfo/types/types.go\npkg/printer/printer.go\npkg/scan/scan.go\nscanner\n```\n\nYou can save the output in a file\n\n```bash\nscanner parse -o=path/to/output.json /path/to/directory\n```\n\n### Metadata\n\nParse file metadata (powered by [`mediainfo`](https://mediaarea.net/en/MediaInfo)) from a filepath\n\n```bash\nscanner metadata /path/to/file\n```\n\nOptions:\n\n- `-o|--output`: output file path, if not set, output is printed in stdout\n- `-j|--json`: output is printed in json format\n\nOutput example\n\n```bash\nUniqueID:\nCompleteName: ./test/media/test.mp3\nFormat: MPEG Audio\nFormatVersion:\nFileSize: 266 KiB\nDuration: 11 s 49 ms\nOverallBitRate: 128 kb/s\nAlbum: P1PDD Le conclave de Troie\nAlbumPerformer: P1PDD \u0026 Mr Piouf\nPartPosition: 1\nTrackName: Introduction\nTrackNamePosition: 1\nPerformer: Mr Piouf\nGenre: Roleplaying game\nRecordedDate: 2016\nFrameRate:\nMovieName:\nEncodedDate:\nWritingApplication:\nWritingLibrary: LAME3.100\nCover: Yes\nCoverType: Cover (front)\nCoverMime: image/jpeg\nComment: http://www.p1pdd.com\nAttachments:\nVideos: []\nAudios:\n[ID: , Format: MPEG Audio, FormatInfo: , FormatProfile: Layer 3, FormatVersion: Version 1, CommercialName: , CodecID: , Duration: 11 s 50 ms, BitRateMode: Constant, BitRate: 128 kb/s, Channel: 2 channels, ChannelLayout: , SamplingRate: 44.1 kHz, FrameRate: 38.281 FPS (1152 SPF), Compression: Lossy, StreamSize: 173 KiB (65%), WritingLibrary: LAME3.100, EncodingSettings: -m j -V 4 -q 2 -lowpass 17 -b 128, Title: , Language: , ServiceKind: , Default: , Forced: ]\nTexts: []\nImages:\n[ID: , Format: JPEG, Width: 640 pixels, Height: 640 pixels, ColorSpace: YUV, ChromaSubsampling: 4:2:0, BitDepth: 8 bits, CompressionMode: Lossy, StreamSize: 91.0 KiB (34%)]\nMenu: []\n```\n\nYou can save the output in a file\n\n```bash\nscanner metadata -o=path/to/output.json /path/to/file\n```\n\n### Info\n\nParse file information from a filepath\n\n```bash\nscanner info /path/to/file\n```\n\nOptions:\n\n- `-o|--output`: output file path, if not set, output is printed in stdout\n- `-j|--json`: output is printed in json format\n\nOutput example\n\n```bash\n\"Name\": \" Alexandre.Astier.LExoconference.2015.mkv\",\n\"Size\": 3752844462,\n\"Mode\": 448,\n\"ModTime\": \"2023-11-24T09:03:37.263929367+01:00\",\n\"IsDir\": false\n```\n\nYou can save the output in a file\n\n```bash\nscanner info -o=path/to/output.json /path/to/file\n```\n\n### Periscope\n\nParse files from a path with info, output is raw JSON\n\n```bash\nscanner periscope /path/to/directory\n```\n\nOptions:\n\n- `-o|--output`: output file path, if not set, output is printed in stdout\n\n## License\n\n[MIT](LICENSE) © Ewilan Rivière\n\n[go-version-src]: https://img.shields.io/static/v1?style=flat\u0026label=Go\u0026message=v1.21\u0026color=00ADD8\u0026logo=go\u0026logoColor=ffffff\u0026labelColor=18181b\n[go-version-href]: https://go.dev/\n[tests-src]: https://img.shields.io/github/actions/workflow/status/ewilan-riviere/files/run-tests.yml?branch=main\u0026label=tests\u0026style=flat\u0026colorA=18181B\n[tests-href]: https://github.com/ewilan-riviere/scanner/actions\n[license-src]: https://img.shields.io/github/license/ewilan-riviere/files.svg?style=flat\u0026colorA=18181B\u0026colorB=00ADD8\n[license-href]: https://github.com/ewilan-riviere/scanner/blob/main/LICENSE\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fewilan-riviere%2Fscanner","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fewilan-riviere%2Fscanner","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fewilan-riviere%2Fscanner/lists"}