Skip to content

Commit 8e62ad0

Browse files
committed
rename git branch master to main
1 parent 44c3b21 commit 8e62ad0

11 files changed

+19
-19
lines changed

.github/workflows/crowdin.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Rebase l10n_master Daily
22

33
on:
44
schedule:
5-
- cron: '31 3 * * *'
5+
- cron: "31 3 * * *"
66

77
jobs:
88
linux:
@@ -20,4 +20,4 @@ jobs:
2020
exit 0
2121
fi
2222
git merge origin/l10n_master
23-
git push origin master
23+
git push origin main

custom-launch.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -113,17 +113,17 @@ Read the API doc for more info: [link](https://pkg.go.dev/github.com/go-rod/rod/
113113
For production scraping system, usually, we will separate the scrapers and browsers into different clusters so that
114114
they can scale separately. Rod provides the module `launcher.Manager` to manage the launcher remotely.
115115
With it we can remotely launch a browser with custom launch flags.
116-
The example to use it is [here](https://github.com/go-rod/rod/blob/master/lib/launcher/rod-manager/main.go).
116+
The example to use it is [here](https://github.com/go-rod/rod/blob/main/lib/launcher/rod-manager/main.go).
117117

118118
Because it's very hard to install chromium correctly on some linux distributions,
119119
Rod provides a docker image to make it consistent cross platforms.
120120
Here's an example to use it:
121121

122122
1. Run the rod image `docker run -p 7317:7317 ghcr.io/go-rod/rod`
123123

124-
2. Open another terminal and run code like this [example](https://github.com/go-rod/rod/blob/master/lib/examples/launch-managed/main.go)
124+
2. Open another terminal and run code like this [example](https://github.com/go-rod/rod/blob/main/lib/examples/launch-managed/main.go)
125125

126-
The image is [tuned](https://github.com/go-rod/rod/blob/master/lib/docker/Dockerfile) for screenshots and fonts among popular natural languages.
126+
The image is [tuned](https://github.com/go-rod/rod/blob/main/lib/docker/Dockerfile) for screenshots and fonts among popular natural languages.
127127
Each container can launch multiple browsers at the same time.
128128

129129
## User mode :id=user-mode
@@ -136,9 +136,9 @@ wsURL := launcher.NewUserMode().MustLaunch()
136136
rod.New().ControlURL(wsURL).MustConnect().NoDefaultDevice()
137137
```
138138

139-
Here's a more detailed example: [code example](https://github.com/go-rod/rod/blob/master/lib/examples/use-rod-like-chrome-extension/main.go).
139+
Here's a more detailed example: [code example](https://github.com/go-rod/rod/blob/main/lib/examples/use-rod-like-chrome-extension/main.go).
140140

141141
## Low-level API
142142

143143
If you want to control every step of the launch process, such as disable the auto-download and use the system's default browser,
144-
check the [example file](https://github.com/go-rod/rod/blob/master/lib/launcher/example_test.go).
144+
check the [example file](https://github.com/go-rod/rod/blob/main/lib/launcher/example_test.go).

custom-websocket.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Customize the WebSocket
22

33
Useful when you want to proxy the transport layer or tune the performance.
4-
Check the example [here](https://github.com/go-rod/rod/blob/master/lib/examples/custom-websocket/main.go).
4+
Check the example [here](https://github.com/go-rod/rod/blob/main/lib/examples/custom-websocket/main.go).

emulation.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ _ = proto.EmulationSetEmulatedMedia{
9999
Usually it's better to make the headless browser completely transparent for the page so that the page cannot tell if it's controlled by a human or robot.
100100
In some cases, some page could use client js to detect if the page is control by a human or a robot, such web WebGL, WebDriver, or http request headers.
101101
You can handcraft a js lib to hide all the traces, or just use lib [stealth](https://github.com/go-rod/stealth):
102-
[code example](https://github.com/go-rod/stealth/blob/master/examples_test.go).
102+
[code example](https://github.com/go-rod/stealth/blob/main/examples_test.go).
103103

104104
If `stealth` lib doesn't work for you, you can just launch the regular user browser with `launcher.NewUserMode`: [User mode](custom-launch.md?id=user-mode).
105105

end-to-end-testing.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# End-to-end Testing
22

3-
Check the [example project](https://github.com/go-rod/rod/tree/master/lib/examples/e2e-testing)
3+
Check the [example project](https://github.com/go-rod/rod/tree/main/lib/examples/e2e-testing)

examples.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Examples
22

3-
Please check the [examples_test.go](https://github.com/go-rod/rod/tree/master/examples_test.go) file first, then check the [examples](https://github.com/go-rod/rod/tree/master/lib/examples) folder.
3+
Please check the [examples_test.go](https://github.com/go-rod/rod/tree/main/examples_test.go) file first, then check the [examples](https://github.com/go-rod/rod/tree/main/lib/examples) folder.
44

55
For more detailed examples, please search the unit tests.
66
Such as the usage of method `HandleAuth`, you can search all the `*_test.go` files that contain `HandleAuth`,
@@ -9,4 +9,4 @@ a lot of usage examples are recorded there.
99

1010
## Comparison with Chromedp
1111

12-
For developers who are familiar with Chromedp, [here](https://github.com/go-rod/rod/tree/master/lib/examples/compare-chromedp) is a comparison of the examples between rod and Chromedp.
12+
For developers who are familiar with Chromedp, [here](https://github.com/go-rod/rod/tree/main/lib/examples/compare-chromedp) is a comparison of the examples between rod and Chromedp.

faq/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ You can jump to it by searching it from here (keyboard shortcut is `F`):
1414

1515
![search-symbol-in-doc](search-symbol-in-doc.png)
1616

17-
For experienced developers please check [Terminology](https://github.com/go-rod/rod/blob/master/.github/CONTRIBUTING.md#terminology).
17+
For experienced developers please check [Terminology](https://github.com/go-rod/rod/blob/main/.github/CONTRIBUTING.md#terminology).

get-started/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ The program will output a screenshot "a.png" like the one below:
4545

4646
## See what's under the hood
4747

48-
For senior developers, you can skip all and read this file: [link](https://github.com/go-rod/rod/blob/master/examples_test.go).
48+
For senior developers, you can skip all and read this file: [link](https://github.com/go-rod/rod/blob/main/examples_test.go).
4949

5050
By default, Rod will disable the browser's UI to maximize the performance.
5151
But when developing an automation task we usually care more about the ease of debugging.

join-development.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ Please read [How To Ask Questions The Smart Way](http://www.catb.org/~esr/faqs/s
66

77
We use Github Projects to manage tasks, you can see the priority and progress of the issues [here](https://github.com/orgs/go-rod/projects/1).
88

9-
If you want to contribute code for this project please read the [Contributor Guide](https://github.com/go-rod/rod/blob/master/.github/CONTRIBUTING.md)
9+
If you want to contribute code for this project please read the [Contributor Guide](https://github.com/go-rod/rod/blob/main/.github/CONTRIBUTING.md)

network.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ page := browser.MustPage("https://test.com/")
109109
page.HijackRequests()
110110
```
111111

112-
For more info check the [hijack tests](https://github.com/go-rod/rod/blob/master/hijack_test.go)
112+
For more info check the [hijack tests](https://github.com/go-rod/rod/blob/main/hijack_test.go)
113113

114114
## Throttling
115115

@@ -137,7 +137,7 @@ since there is no point on loading fonts/css. Example below:
137137
```go
138138
func main() {
139139
page := rod.New().MustConnect().MustPage("")
140-
140+
141141
router := page.HijackRequests()
142142

143143
router.MustAdd("*.png", func(ctx *rod.Hijack) {

why-rod.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ When a crash happens, Chromedp will leave the zombie browser process on Windows
2020

2121
Rod is more configurable, such as you can even replace the WebSocket lib with the lib you like.
2222

23-
For direct code comparison you can check [here](https://github.com/go-rod/rod/tree/master/lib/examples/compare-chromedp). If you compare the example called `logic` between [rod](https://github.com/go-rod/rod/tree/master/lib/examples/compare-chromedp/logic/main.go) and [chromedp](https://github.com/chromedp/examples/blob/master/logic/main.go), you will find out how simpler rod is.
23+
For direct code comparison you can check [here](https://github.com/go-rod/rod/tree/main/lib/examples/compare-chromedp). If you compare the example called `logic` between [rod](https://github.com/go-rod/rod/tree/main/lib/examples/compare-chromedp/logic/main.go) and [chromedp](https://github.com/chromedp/examples/blob/master/logic/main.go), you will find out how simpler rod is.
2424

2525
With Chromedp, you have to use their verbose DSL-like tasks to handle code logic. Chromedp uses several wrappers to handle execution with context and options, which makes it very hard to understand their code when bugs happen. The heavily used interfaces make the static types useless when tracking issues. In contrast, Rod uses as few interfaces as possible.
2626

@@ -76,7 +76,7 @@ If you want to cooperate with us to create a testing focused framework base on R
7676

7777
Rod is the name of the control device for puppetry, such as the brown stick in the image below:
7878

79-
![rod](https://user-images.githubusercontent.com/1415488/80178856-31cd8880-863a-11ea-83e9-64f84be3282d.png ':size=200')
79+
![rod](https://user-images.githubusercontent.com/1415488/80178856-31cd8880-863a-11ea-83e9-64f84be3282d.png ":size=200")
8080

8181
The meaning is we are the puppeteer, the browser is the puppet, we use the rod to control the puppet.
8282

0 commit comments

Comments
 (0)