{"id":23701119,"url":"https://github.com/ehanlin/duration-format","last_synced_at":"2026-01-29T10:30:15.074Z","repository":{"id":20842133,"uuid":"24128368","full_name":"eHanlin/duration-format","owner":"eHanlin","description":"duration formatter","archived":false,"fork":false,"pushed_at":"2015-04-10T08:40:23.000Z","size":120,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-01-30T12:47:34.964Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"CoffeeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"peterbraden/node-opencv","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eHanlin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-09-17T03:29:51.000Z","updated_at":"2016-02-17T13:45:59.000Z","dependencies_parsed_at":"2022-07-07T15:58:57.234Z","dependency_job_id":null,"html_url":"https://github.com/eHanlin/duration-format","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eHanlin%2Fduration-format","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eHanlin%2Fduration-format/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eHanlin%2Fduration-format/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eHanlin%2Fduration-format/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eHanlin","download_url":"https://codeload.github.com/eHanlin/duration-format/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239776600,"owners_count":19695139,"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":[],"created_at":"2024-12-30T09:32:10.471Z","updated_at":"2026-01-29T10:30:15.017Z","avatar_url":"https://github.com/eHanlin.png","language":"CoffeeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 時間長度格式化工具  duration formatter\n\n```javascript\n\nvar df = require 'duration-format'\n\nvar S = 1000\nvar M = 60 * S\nvar H = 60 * M\nvar D = 24 * H\n\nvar duration = 2*D + 3*H + 45*M + 6*S + 78\n\ndf(duration, '#{D} Day #{H} : #{M} : #{S} . #{MS}')\n// 2 Day 3 : 45 : 6 . 78\ndf(duration, '#{4D} Day #{2H} : #{2M} : #{2S} . #{3MS}')\n// 0002 Day 03 : 45 : 06 . 078\ndf(duration, '#{2D} Day #{2M} : #{2S}')\n// 02 Day 225 : 06\ndf(duration, '#{2H} : #{2M} : #{2S}')\n// 51 : 45 : 06\ndf(duration, '#{2M} : #{2S}')\n// 3105 : 06\ndf(duration, '#{2H} : #{2S}')\n// 51 : 2706\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fehanlin%2Fduration-format","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fehanlin%2Fduration-format","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fehanlin%2Fduration-format/lists"}