Skip to content

Commit

Permalink
Added CI and badges.
Browse files Browse the repository at this point in the history
  • Loading branch information
dsoprea committed Jan 10, 2019
1 parent 02cb4d0 commit 35b7260
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
13 changes: 13 additions & 0 deletions .travis.yml
@@ -0,0 +1,13 @@
language: go
go:
- master
- stable
- "1.11"
- "1.10"
- "1.9"
- "1.8"
install:
- go get -t ./...
- go get github.com/mattn/goveralls
script:
- goveralls -v -service=travis-ci
10 changes: 9 additions & 1 deletion README.md
@@ -1,6 +1,14 @@
[![Build Status](https://travis-ci.org/dsoprea/go-time-index.svg?branch=master)](https://travis-ci.org/dsoprea/go-time-index)
[![Coverage Status](https://coveralls.io/repos/github/dsoprea/go-time-index/badge.svg?branch=master)](https://coveralls.io/github/dsoprea/go-time-index?branch=master)
[![GoDoc](https://godoc.org/github.com/dsoprea/go-time-index?status.svg)](https://godoc.org/github.com/dsoprea/go-time-index)


# Overview

An implementation of a `time` slice (`[]time.Time`) that contains semantics for searching, sorting a slice, and incrementally sorting when starting from an empty slice (insertion sort).

Features:

## Features

- `timeindex`.`TimeSlice` (type alias for `[]time.Time`) providing `Search`, `Sort`, and `Add` (in addition to fulfilling the `sort.Interface` interface).
- `timeindex`.`TimeSlice` also provides `SearchNearest` method to invoke a callback for all of the times near a given time and range of tolerance (expressed as a `time.Duration`).
Expand Down

0 comments on commit 35b7260

Please sign in to comment.