{"id":45906628,"url":"https://github.com/jpzk/twitter-intervals","last_synced_at":"2026-02-28T03:19:25.275Z","repository":{"id":57726388,"uuid":"96766968","full_name":"jpzk/twitter-intervals","owner":"jpzk","description":"The Missing Intervals of Twitter Util Time","archived":false,"fork":false,"pushed_at":"2018-09-04T03:09:46.000Z","size":16,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-07-01T13:05:06.260Z","etag":null,"topics":["date","intervals","time","twitter","utility"],"latest_commit_sha":null,"homepage":"","language":"Scala","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jpzk.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-07-10T10:50:54.000Z","updated_at":"2023-07-01T13:05:06.261Z","dependencies_parsed_at":"2022-09-26T21:50:45.825Z","dependency_job_id":null,"html_url":"https://github.com/jpzk/twitter-intervals","commit_stats":null,"previous_names":[],"tags_count":0,"template":null,"template_full_name":null,"purl":"pkg:github/jpzk/twitter-intervals","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpzk%2Ftwitter-intervals","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpzk%2Ftwitter-intervals/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpzk%2Ftwitter-intervals/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpzk%2Ftwitter-intervals/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jpzk","download_url":"https://codeload.github.com/jpzk/twitter-intervals/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpzk%2Ftwitter-intervals/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29923569,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T19:37:42.220Z","status":"online","status_checked_at":"2026-02-28T02:00:07.010Z","response_time":90,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["date","intervals","time","twitter","utility"],"created_at":"2026-02-28T03:19:24.752Z","updated_at":"2026-02-28T03:19:25.270Z","avatar_url":"https://github.com/jpzk.png","language":"Scala","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Twitter Intervals\n\n[![Build Status](https://travis-ci.org/jpzk/twitter-intervals.svg?branch=master)](https://travis-ci.org/jpzk/twitter-intervals)  [![codecov](https://codecov.io/gh/jpzk/twitter-intervals/branch/master/graph/badge.svg)](https://codecov.io/gh/jpzk/twitter-intervals) [![License](http://img.shields.io/:license-Apache%202-grey.svg)](http://www.apache.org/licenses/LICENSE-2.0.txt) [![GitHub stars](https://img.shields.io/github/stars/jpzk/twitter-intervals.svg?style=flat)](https://github.com/jpzk/twitter-intervals/stargazers) \n\nThe missing intervals for the [Twitter Util](https://github.com/twitter/util) library. Currently supports test on intersection, and operations union and minus. Feel free to contribute.\n\n## Install\n\nAvailable on Maven Central Repositories\n\n    libraryDependencies += \"com.madewithtea\" %% \"twitterintervals\" % \"0.6.0\" \n\n## Example\n \n    import com.twitter.conversions.time._\n    import com.twitter.util.{Time, Duration}\n    import com.madewithtea.twitterintervals.Interval\n\n    val a = Interval(Time.Zero, Time.Zero + 1.day)\n    val b = Interval(Time.Zero + 1.hour, Time.Zero + 1.day)\n\n    // test on intersection\n    a intersects b shouldEqual true \n\n    // union \n    a union b shouldEqual Interval(Time.Zero, Time.Zero + 1.day)\n\n    // returning intersection intervals as Set of intervals\n    a minus b shouldEqual Set(Interval(Time.Zero, Time.Zero + 1.hour))\n\n    // can be empty\n    a minus a shouldEqual Set()\n\n    // using Twitter Time and Duration (conversions) with Intervals\n    a.duration shouldEqual 1.day\n\n    \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpzk%2Ftwitter-intervals","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjpzk%2Ftwitter-intervals","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpzk%2Ftwitter-intervals/lists"}