Skip to content

Commit a3379b9

Browse files
committed
update README
1 parent df4335a commit a3379b9

File tree

2 files changed

+12
-15
lines changed

2 files changed

+12
-15
lines changed

README.md

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,20 @@ This is a go library and command-line tools for handling .srt, .vtt and .ssa sub
1010

1111
Windows and macOS binaries are available under [Releases](https://github.com/martinlindhe/subtitles/releases)
1212

13-
Or install them from source:
13+
Or install them directly from git:
1414

1515
```
1616
go get -u github.com/martinlindhe/subtitles/...
1717
```
1818

1919

20-
# Example - convert srt to vtt
20+
21+
# Sub-projects
22+
23+
- [subber](https://github.com/martinlindhe/subtitles/tree/master/cmd/subber) command line tool for subtitles
24+
25+
26+
# Library example - convert srt to vtt
2127

2228
```go
2329
import "github.com/martinlindhe/subtitles"
@@ -29,7 +35,6 @@ in := "1\n" +
2935
"1\n" +
3036
"00:01:09,630 --> 00:01:11,005\n" +
3137
"No ninja!\n"
32-
3338
res, _ := subtitles.NewFromSRT(in)
3439

3540
// Output: WEBVTT
@@ -43,25 +48,17 @@ fmt.Println(res.AsVTT())
4348
```
4449

4550

46-
# Example - download subtitle from thesubdb.com
51+
# Library example - download subtitles
4752

4853
```go
4954
f, _ := os.Open(fileName)
5055
defer f.Close()
5156

5257
finder := subtitles.NewSubFinder(f, fileName, "en")
53-
5458
text, err := finder.TheSubDb()
5559
```
5660

5761

58-
# Sub-projects
59-
60-
- [subber](https://github.com/martinlindhe/subtitles/tree/master/cmd/subber) command line tool for subtitles
61-
- [ssa2srt](https://github.com/martinlindhe/subtitles/tree/master/cmd/ssa2srt) for converting .ssa to .srt
62-
- [dcsub2srt](https://github.com/martinlindhe/subtitles/tree/master/cmd/dcsub2srt) for converting dcsubtitles to .srt
63-
64-
6562
# License
6663

6764
Under [MIT](LICENSE)

cmd/subber/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ go install github.com/martinlindhe/subtitles/cmd/subber
3333

3434
## Usage
3535

36-
### To download subtitles for a video file
36+
### Download subtitles for a video
3737

3838
```
3939
$ subber movie.mp4
@@ -61,7 +61,7 @@ $ subber subtitle.srt
6161
Removing caption 21 [<font color="#FFFF00"> Captions by VITAC </font><font color="#00FFFF"> www.vitac.com</font>]
6262
```
6363

64-
### Strip html tags from .srt
64+
### Strip html from .srt
6565

6666
```
6767
$ subber subtitle.srt --filter="html"
@@ -78,7 +78,7 @@ $ subber subtitle.srt --filter="caps"
7878
[caps] right, to go? -> Right, to go?
7979
```
8080

81-
### Convert a .ssa to a .srt
81+
### Convert .ssa to .srt
8282

8383
```
8484
$ subber subtitle.ssa -o subtitle.srt

0 commit comments

Comments
 (0)