Skip to content

Commit ef4dde2

Browse files
committed
Fix -v and add updating information
1 parent f2cca01 commit ef4dde2

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,16 @@ brew install mactop
3939
sudo mactop
4040
```
4141

42+
## Updating via Homebrew
43+
44+
```bash
45+
brew update
46+
```
47+
48+
```bash
49+
brew upgrade mactop
50+
```
51+
4252
## Installation
4353

4454
To install `mactop`, follow these steps:

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ func StderrToLogfile(logfile *os.File) {
250250
func main() {
251251

252252
version := "v0.1.5"
253-
if len(os.Args) > 1 && os.Args[1] == "--version" {
253+
if len(os.Args) > 1 && os.Args[1] == "--version" || len(os.Args) > 1 && os.Args[1] == "-v" {
254254
fmt.Println("mactop version:", version)
255255
os.Exit(0)
256256
}

0 commit comments

Comments
 (0)