An open API service indexing awesome lists of open source software.

https://github.com/koorgoo/rotate

Rotation for *os.File
https://github.com/koorgoo/rotate

log logging logrotate logrus rotate zap

Last synced: 6 months ago
JSON representation

Rotation for *os.File

Awesome Lists containing this project

README

          

# rotate [![GoDoc][doc-img]][doc] [![Build Status][ci-img]][ci]

Rotation for `*os.File`.

## Installation

```
go get -u github.com/koorgoo/rotate
```

## Quick Start

```
f := rotate.MustOpen(name, rotate.Config{
Bytes: rotate.MB,
Count: 10,
})
defer f.Close()
```

See [examples][examples].

[doc-img]: https://godoc.org/github.com/koorgoo/rotate?status.svg
[doc]: https://godoc.org/github.com/koorgoo/rotate
[ci-img]: https://travis-ci.org/koorgoo/rotate.svg?branch=master
[ci]: https://travis-ci.org/koorgoo/rotate
[examples]: https://github.com/koorgoo/rotate/tree/master/example