Fork of github.com/shu-go/vvin
Go to file
Evan f10a5927c7 Merge pull request 'fix(deps): update module github.com/shu-go/gli/v2 to v2.3.0' (#5) from renovate/github.com-shu-go-gli-v2-2.x into main
Reviewed-on: #5
2024-05-12 00:44:47 -04:00
LICENSE add: LICENSE 2019-11-10 12:15:44 +09:00
README.md Update README.md 2023-10-16 16:15:05 -04:00
cmd_alpha.go Update from upstream by squashing 2024-04-04 10:50:39 -04:00
cmd_minmax.go Mark as Windows only 2023-10-17 00:00:50 -04:00
cmd_resize.go Update from upstream by squashing 2024-04-04 10:50:39 -04:00
cmd_topmost.go Mark as Windows only 2023-10-17 00:00:50 -04:00
cmd_wait.go Update from upstream by squashing 2024-04-04 10:50:39 -04:00
go.mod fix(deps): update module github.com/shu-go/gli/v2 to v2.3.0 2024-05-12 04:44:33 +00:00
go.sum fix(deps): update module github.com/shu-go/gli/v2 to v2.3.0 2024-05-12 04:44:33 +00:00
renovate.json Add Renovate Bot support 2023-11-03 09:54:32 -04:00
vvin.go Return from the function 2024-04-05 22:49:59 -04:00

README.md

keep waking Windows up

MIT License

Usage

package main

import (
	"git.bigun.dev/evan/vvin"
)

// program implements vvin

func main() {

	// Bring this program's window to the top.
	err := vvin.Vvin([]string{"topmost"})
	if err != nil {
		log.Println(err)
	}
}

Sub commands:
  minimize, min     minimize/restore
  maximize, max     maximize/restore
  resize, move, mv  resize/move
  alpha             set alpha 0%(transparent) - 100%(opaque)
  topmost           set always on top/restore
  wait              wait for a window is opened/closed ([--close] {Title})

Options:
  -t, --target WINDOW_TITLE  default to current window

minimize/restore

vvin.Vvin([]string{"-t", "notepad", "min"})

vvin.Vvin([]string{"-t", "notepad", "min", "--restore"})
vvin.Vvin([]string{"-t", "notepad", "min", "-r"})

resize

vvin.Vvin([]string{"-t", "notepad", "resize", "-x", "0", "-y", "0", "-w", "60%", "-h", "100%"})

alpha

vvin.Vvin([]string{"-t", "notepad", "alpha", "75%"})

always on top

vvin.Vvin([]string{"-t", "notepad", "topmost"})

vvin.Vvin([]string{"-t", "notepad", "topmost", "--restore"})
vvin.Vvin([]string{"-t", "notepad", "topmost", "-r"})

wait

wait for a window to appear

vvin.Vvin([]string{"wait", "notepad"})

wait closed

vvin.Vvin([]string{"wait", "notepad", "--closed"})