mirror of
https://github.com/jquery/jquery.git
synced 2025-01-10 18:24:24 +00:00
Build: Rename master to main across the repository
The default branch was updated, this updates the remaining occurrences in code
& comments.
Closes gh-4838
(cherry picked from commit 8ae477a432
)
This commit is contained in:
parent
15b62a2eb5
commit
627c573ac6
@ -85,16 +85,16 @@ Change directory to the newly created dir jquery/
|
|||||||
$ cd jquery
|
$ cd jquery
|
||||||
```
|
```
|
||||||
|
|
||||||
Add the jQuery master as a remote. I label mine "upstream"
|
Add the jQuery main as a remote. I label mine "upstream"
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ git remote add upstream git://github.com/jquery/jquery.git
|
$ git remote add upstream git://github.com/jquery/jquery.git
|
||||||
```
|
```
|
||||||
|
|
||||||
Get in the habit of pulling in the "upstream" master to stay up to date as jQuery receives new commits
|
Get in the habit of pulling in the "upstream" main to stay up to date as jQuery receives new commits
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ git pull upstream master
|
$ git pull upstream main
|
||||||
```
|
```
|
||||||
|
|
||||||
Run the build script
|
Run the build script
|
||||||
|
@ -102,7 +102,7 @@ Some example modules that can be excluded are:
|
|||||||
|
|
||||||
As a special case, you may also replace Sizzle by using a special flag `grunt custom:-sizzle`.
|
As a special case, you may also replace Sizzle by using a special flag `grunt custom:-sizzle`.
|
||||||
|
|
||||||
- **sizzle**: The Sizzle selector engine. When this module is excluded, it is replaced by a rudimentary selector engine based on the browser's `querySelectorAll` method that does not support jQuery selector extensions or enhanced semantics. See the [selector-native.js](https://github.com/jquery/jquery/blob/master/src/selector-native.js) file for details.
|
- **sizzle**: The Sizzle selector engine. When this module is excluded, it is replaced by a rudimentary selector engine based on the browser's `querySelectorAll` method that does not support jQuery selector extensions or enhanced semantics. See the [selector-native.js](https://github.com/jquery/jquery/blob/main/src/selector-native.js) file for details.
|
||||||
|
|
||||||
*Note*: Excluding Sizzle will also exclude all jQuery selector extensions (such as `effects/animatedSelector` and `css/hiddenVisibleSelectors`).
|
*Note*: Excluding Sizzle will also exclude all jQuery selector extensions (such as `effects/animatedSelector` and `css/hiddenVisibleSelectors`).
|
||||||
|
|
||||||
@ -227,7 +227,7 @@ As the source code is handled by the Git version control system, it's useful to
|
|||||||
If you want to purge your working directory back to the status of upstream, the following commands can be used (remember everything you've worked on is gone after these):
|
If you want to purge your working directory back to the status of upstream, the following commands can be used (remember everything you've worked on is gone after these):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git reset --hard upstream/master
|
git reset --hard upstream/main
|
||||||
git clean -fdx
|
git clean -fdx
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -285,7 +285,7 @@ throws( block, [expected], [message] );
|
|||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Test Suite Convenience Methods Reference (See [test/data/testinit.js](https://github.com/jquery/jquery/blob/master/test/data/testinit.js))
|
Test Suite Convenience Methods Reference (See [test/data/testinit.js](https://github.com/jquery/jquery/blob/main/test/data/testinit.js))
|
||||||
------------------------------
|
------------------------------
|
||||||
|
|
||||||
### Returns an array of elements with the given IDs ###
|
### Returns an array of elements with the given IDs ###
|
||||||
|
@ -30,9 +30,9 @@ module.exports = function( Release, files, complete ) {
|
|||||||
Release.exec( `git clone ${ distRemote } ${ Release.dir.dist }`,
|
Release.exec( `git clone ${ distRemote } ${ Release.dir.dist }`,
|
||||||
"Error cloning repo." );
|
"Error cloning repo." );
|
||||||
|
|
||||||
// Distribution always works on master
|
// Distribution always works on main
|
||||||
Release.chdir( Release.dir.dist );
|
Release.chdir( Release.dir.dist );
|
||||||
Release.exec( "git checkout master", "Error checking out branch." );
|
Release.exec( "git checkout main", "Error checking out branch." );
|
||||||
console.log();
|
console.log();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -144,8 +144,8 @@ module.exports = function( Release, files, complete ) {
|
|||||||
Release.exec(
|
Release.exec(
|
||||||
`git push ${
|
`git push ${
|
||||||
Release.isTest ? " --dry-run" : ""
|
Release.isTest ? " --dry-run" : ""
|
||||||
} ${ distRemote } master --tags`,
|
} ${ distRemote } main --tags`,
|
||||||
"Error pushing master and tags to git repo."
|
"Error pushing main and tags to git repo."
|
||||||
);
|
);
|
||||||
|
|
||||||
// Set repo for npm publish
|
// Set repo for npm publish
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
"homepage": "https://jquery.com",
|
"homepage": "https://jquery.com",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "OpenJS Foundation and other contributors",
|
"name": "OpenJS Foundation and other contributors",
|
||||||
"url": "https://github.com/jquery/jquery/blob/master/AUTHORS.txt"
|
"url": "https://github.com/jquery/jquery/blob/main/AUTHORS.txt"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -69,7 +69,7 @@ QUnit.test( "disconnected element", function( assert ) {
|
|||||||
|
|
||||||
var result = jQuery( document.createElement( "div" ) ).offset();
|
var result = jQuery( document.createElement( "div" ) ).offset();
|
||||||
|
|
||||||
// These tests are solely for master/compat consistency
|
// These tests are solely for main/compat consistency
|
||||||
// Retrieving offset on disconnected/hidden elements is not officially
|
// Retrieving offset on disconnected/hidden elements is not officially
|
||||||
// valid input, but will return zeros for back-compat
|
// valid input, but will return zeros for back-compat
|
||||||
assert.equal( result.top, 0, "Retrieving offset on disconnected elements returns zeros (gh-2310)" );
|
assert.equal( result.top, 0, "Retrieving offset on disconnected elements returns zeros (gh-2310)" );
|
||||||
@ -86,7 +86,7 @@ QUnit.test( "hidden (display: none) element", function( assert ) {
|
|||||||
|
|
||||||
node.remove();
|
node.remove();
|
||||||
|
|
||||||
// These tests are solely for master/compat consistency
|
// These tests are solely for main/compat consistency
|
||||||
// Retrieving offset on disconnected/hidden elements is not officially
|
// Retrieving offset on disconnected/hidden elements is not officially
|
||||||
// valid input, but will return zeros for back-compat
|
// valid input, but will return zeros for back-compat
|
||||||
assert.equal( result.top, 0, "Retrieving offset on hidden elements returns zeros (gh-2310)" );
|
assert.equal( result.top, 0, "Retrieving offset on hidden elements returns zeros (gh-2310)" );
|
||||||
@ -484,7 +484,7 @@ testIframe( "scroll", "offset/scroll.html", function( assert, $, win ) {
|
|||||||
assert.equal( $( "#scroll-1-1" ).offset().top, 11, "jQuery('#scroll-1-1').offset().top" );
|
assert.equal( $( "#scroll-1-1" ).offset().top, 11, "jQuery('#scroll-1-1').offset().top" );
|
||||||
assert.equal( $( "#scroll-1-1" ).offset().left, 11, "jQuery('#scroll-1-1').offset().left" );
|
assert.equal( $( "#scroll-1-1" ).offset().left, 11, "jQuery('#scroll-1-1').offset().left" );
|
||||||
|
|
||||||
// These tests are solely for master/compat consistency
|
// These tests are solely for main/compat consistency
|
||||||
// Retrieving offset on disconnected/hidden elements is not officially
|
// Retrieving offset on disconnected/hidden elements is not officially
|
||||||
// valid input, but will return zeros for back-compat
|
// valid input, but will return zeros for back-compat
|
||||||
assert.equal( $( "#hidden" ).offset().top, 0, "Hidden elements do not subtract scroll" );
|
assert.equal( $( "#hidden" ).offset().top, 0, "Hidden elements do not subtract scroll" );
|
||||||
|
Loading…
Reference in New Issue
Block a user