https://github.com/abhinandan-khurana/go-screenshot-safari
This project provides a straightforward implementation of Selenium (in GoLang) with the Safari browser for capturing screenshots of web pages. It addresses the limitations posed by certain websites that require specific browsers, such as Chrome (version 96.0 or higher), Edge, or Safari, to function properly.
https://github.com/abhinandan-khurana/go-screenshot-safari
cli-tool cli-utility cybersecurity endpoint-security go golang screenshot-utility security-tools
Last synced: 25 days ago
JSON representation
This project provides a straightforward implementation of Selenium (in GoLang) with the Safari browser for capturing screenshots of web pages. It addresses the limitations posed by certain websites that require specific browsers, such as Chrome (version 96.0 or higher), Edge, or Safari, to function properly.
- Host: GitHub
- URL: https://github.com/abhinandan-khurana/go-screenshot-safari
- Owner: Abhinandan-Khurana
- Created: 2024-08-06T05:58:17.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-09-11T08:29:45.000Z (about 1 year ago)
- Last Synced: 2025-01-10T15:51:20.800Z (11 months ago)
- Topics: cli-tool, cli-utility, cybersecurity, endpoint-security, go, golang, screenshot-utility, security-tools
- Language: Go
- Homepage:
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# go-screenshot-safari
## Description
This project provides a straightforward implementation of Selenium (in GoLang) with the Safari browser for capturing screenshots of web pages. It addresses the limitations posed by certain websites that require specific browsers, such as Chrome (version 96.0 or higher), Edge, or Safari, to function properly.
### Installation
```bash
go install -v github.com/Abhinandan-Khurana/go-screenshot-safari@v1.0.2
```
### Pre-requisites
Goto Safari > Develop > Developer Settings > Allow remote Automation (check this option)
And make sure to run [selenium server](https://selenium-release.storage.googleapis.com/index.html?path=3.5/) --> `java -jar selenium-server-standalone-3.5.3.jar`
## Usage
```bash
-interval_wait_time int
Time to wait between taking screenshots of URLs (in seconds) (default 1)
-load_wait_time int
Time to wait for a URL to load before taking a screenshot (in seconds) (default 2)
-output_dir string
The output directory to save screenshots (default "screenshots")
-urls_file string
Path to the file containing the list of URLs (default "urls.txt")
```
### Example usage
```bash
go run . -urls_file urls.txt -output_dir screenshots -load_wait_time 2 -interval_wait_time 1
```