https://github.com/haya14busa/offset
get file position from offset
https://github.com/haya14busa/offset
cli go
Last synced: about 1 year ago
JSON representation
get file position from offset
- Host: GitHub
- URL: https://github.com/haya14busa/offset
- Owner: haya14busa
- License: mit
- Created: 2020-02-02T07:45:22.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-05-07T11:21:44.000Z (about 6 years ago)
- Last Synced: 2024-10-11T12:02:06.688Z (over 1 year ago)
- Topics: cli, go
- Language: Shell
- Homepage:
- Size: 20.5 KB
- Stars: 4
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# offset - get file position from offset
[](https://github.com/haya14busa/offset/actions)
[](https://godoc.org/github.com/haya14busa/offset)
## Usage
```go
import "github.com/haya14busa/offset"
```
[](https://godoc.org/github.com/haya14busa/offset)
## CLI
### Installation
```shell
# Go
$ go get github.com/haya14busa/offset/cmd/offset
```
### offset -h
```
Usage: offset [FLAGS] [File]
Return position from given offset
Flags:
-offset int
byte offset
-version
print version
GitHub: https://github.com/haya14busa/offset
```
### Example
```shell
$ offset -offset 14 LICENSE
{"file":"LICENSE","offset":14,"line":3,"column":1}
```