winscript

command module
v0.0.0-...-d6f239a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 13, 2025 License: BSD-3-Clause Imports: 1 Imported by: 0

README ΒΆ

WinScript

Platform Language License Status PRs Welcome

⚑ WinScript is a lightweight scripting language for Windows automation.
Inspired by AppleScript, written in Go, and designed to be simple, readable, and powerful.


✨ Features

  • πŸ–₯ Launch and control Windows applications
  • 🎯 Simulate mouse movement and clicks
  • ⌨️ Simulate keystrokes and text input
  • ⏱ Simple wait and delay functionality
  • πŸ“œ Human-readable .ws syntax
  • πŸ”§ Cross-compatible CLI with Cobra
  • 🧩 Easy to extend with Go

πŸš€ Quick Example

open "notepad.exe"
wait 2s
type "Hello from WinScript!"
move_mouse 400 300
click "left"

πŸ“ Save your scripts as .ws files.


πŸ”§ Installation

git clone https://github.com/1strewave/winscript.git
cd winscript
go build -o winscript

βœ… Optionally, add the built binary folder to your system PATH for global access.

To install the path permanently via script, you can use install.bat.


πŸ’» CLI Usage

WinScript provides a command-line interface using Cobra.

πŸ”Ή Available Commands:
winscript [file]           # Run a script file directly
winscript run script.ws    # Explicit 'run' command
winscript help             # Show available commands
winscript docs             # Show documentation keywords
winscript version          # Print current version
πŸ”Έ Examples:
winscript hello.ws
winscript run scripts/boot.ws
winscript docs

🧠 Language Keywords

Keyword Description Example
open Launch an application open "notepad.exe"
type Type a string type "Hello, world!"
press Press a single key press "enter"
hotkey Key combination hotkey "ctrl+s"
move_mouse Move mouse cursor move_mouse 500 300
click Mouse click click "left"
wait Wait for time wait 2s
log Output text to console log "Starting script..."

πŸ“˜ More details coming soon in docs/commands.md


πŸ›£ Roadmap

  • CLI interface with Cobra
  • Script parser and interpreter
  • Core automation commands
  • Variables (set name = "Alice")
  • Conditional logic (if, else)
  • Loops (repeat, while)
  • User-defined functions
  • REPL / interactive mode
  • RayLib dependency
  • GUI interface
  • Windows Installer (.msi)
  • WS IDE (for winscript)

🀝 Contributing

Pull requests, issues, ideas, and feedback are welcome.
If you’d like to help shape the future of WinScript β€” let’s build it together!


πŸ§‘β€πŸ’» Author

WinScript is a hobby project created by @1strewave to explore language design and automation on Windows using Go.
Made with ❀️ for code, simplicity, and creativity.

Documentation ΒΆ

The Go Gopher

There is no documentation for this package.

Directories ΒΆ

Path Synopsis
internal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL