git 3.1.0 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/pull_request_template.md +1 -1
- data/.github/workflows/continuous_integration.yml +1 -1
- data/.github/workflows/enforce_conventional_commits.yml +1 -1
- data/.github/workflows/experimental_continuous_integration.yml +1 -1
- data/.github/workflows/release.yml +1 -1
- data/.gitignore +2 -1
- data/.release-please-manifest.json +1 -1
- data/CHANGELOG.md +13 -0
- data/README.md +16 -7
- data/lib/git/lib.rb +1 -1
- data/lib/git/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8ea6b964531a2d91cdc46c4e4c7a6d9f79251f246f2c8856c271b989c6d22800
|
4
|
+
data.tar.gz: 3fd581082807719899cdbe85eea5ca8eca35803402f6822c66bd5b95b27de10b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ae34ed0370f1ac66b68c03e13ef16d9415e531f3ebe0b7af906dc6d9150c4fc0eec63da7dde987530f7a24bf17966cb3053b40723e0056c78652763340b8e71c
|
7
|
+
data.tar.gz: ec675f610d8d193dac8c0debca9de1480d154b3d09c34e172dbb0e68d7a47625fdcb7d8bef7a5625e3fef8dfd10e029e1ff682ee033b698beebae43414b3454f
|
@@ -1,4 +1,4 @@
|
|
1
|
-
Review our [guidelines for contributing](https://github.com/ruby-git/ruby-git/blob/
|
1
|
+
Review our [guidelines for contributing](https://github.com/ruby-git/ruby-git/blob/main/CONTRIBUTING.md) to this repository. A good start is to:
|
2
2
|
|
3
3
|
* Write tests for your changes
|
4
4
|
* Run `rake` before pushing
|
data/.gitignore
CHANGED
data/CHANGELOG.md
CHANGED
@@ -5,6 +5,19 @@
|
|
5
5
|
|
6
6
|
# Change Log
|
7
7
|
|
8
|
+
## [3.1.1](https://github.com/ruby-git/ruby-git/compare/v3.1.0...v3.1.1) (2025-07-02)
|
9
|
+
|
10
|
+
|
11
|
+
### Bug Fixes
|
12
|
+
|
13
|
+
* Raise a Git::FailedError if depth < 0 is passed to Git.clone ([803253e](https://github.com/ruby-git/ruby-git/commit/803253ea2dd2b69b099c0d1919b03ac65c800264)), closes [#805](https://github.com/ruby-git/ruby-git/issues/805)
|
14
|
+
|
15
|
+
|
16
|
+
### Other Changes
|
17
|
+
|
18
|
+
* Announce default branch change in README ([e04f08e](https://github.com/ruby-git/ruby-git/commit/e04f08e202ae54286033b4d0a75c47f124bd63e2))
|
19
|
+
* Update the project's default branch from 'master' to 'main' ([a5aa75f](https://github.com/ruby-git/ruby-git/commit/a5aa75fd04a71cd8236b8c8481a067c0a47b24b9))
|
20
|
+
|
8
21
|
## [3.1.0](https://github.com/ruby-git/ruby-git/compare/v3.0.2...v3.1.0) (2025-05-18)
|
9
22
|
|
10
23
|
|
data/README.md
CHANGED
@@ -8,9 +8,10 @@
|
|
8
8
|
[](https://badge.fury.io/rb/git)
|
9
9
|
[](https://rubydoc.info/gems/git/)
|
10
10
|
[](https://rubydoc.info/gems/git/file/CHANGELOG.md)
|
11
|
-
[](https://github.com/ruby-git/ruby-git/actions?query=workflow%3ACI)
|
12
12
|
[](https://conventionalcommits.org)
|
13
13
|
|
14
|
+
- [📢 Default Branch Rename 📢](#-default-branch-rename-)
|
14
15
|
- [📢 We've Switched to Conventional Commits 📢](#-weve-switched-to-conventional-commits-)
|
15
16
|
- [Summary](#summary)
|
16
17
|
- [Install](#install)
|
@@ -21,6 +22,14 @@
|
|
21
22
|
- [Ruby version support policy](#ruby-version-support-policy)
|
22
23
|
- [License](#license)
|
23
24
|
|
25
|
+
## 📢 Default Branch Rename 📢
|
26
|
+
|
27
|
+
On June 6th, 2025, the default branch was renamed from 'master' to 'main'.
|
28
|
+
|
29
|
+
Instructions for renaming your local or forked branch to match can be found in the
|
30
|
+
gist [Default Branch Name
|
31
|
+
Change](https://gist.github.com/jcouball/580a10e395f7fdfaaa4297bbe816cc7d).
|
32
|
+
|
24
33
|
## 📢 We've Switched to Conventional Commits 📢
|
25
34
|
|
26
35
|
To enhance our development workflow, enable automated changelog generation, and pave
|
@@ -275,8 +284,8 @@ g.branches # returns Git::Branch objects
|
|
275
284
|
g.branches.local
|
276
285
|
g.current_branch
|
277
286
|
g.branches.remote
|
278
|
-
g.branches[:
|
279
|
-
g.branches['origin/
|
287
|
+
g.branches[:main].gcommit
|
288
|
+
g.branches['origin/main'].gcommit
|
280
289
|
|
281
290
|
g.grep('hello') # implies HEAD
|
282
291
|
g.blob('v2.5:Makefile').grep('hello')
|
@@ -333,7 +342,7 @@ Git.ls_remote('https://github.com/ruby-git/ruby-git.git') # returns a hash conta
|
|
333
342
|
Git.ls_remote('/path/to/local/repo')
|
334
343
|
Git.ls_remote() # same as Git.ls_remote('.')
|
335
344
|
|
336
|
-
Git.default_branch('https://github.com/ruby-git/ruby-git') #=> '
|
345
|
+
Git.default_branch('https://github.com/ruby-git/ruby-git') #=> 'main'
|
337
346
|
```
|
338
347
|
|
339
348
|
And here are the operations that will need to write to your git repository.
|
@@ -406,13 +415,13 @@ g.branch('new_branch') # creates new or fetches existing
|
|
406
415
|
g.branch('new_branch').checkout
|
407
416
|
g.branch('new_branch').delete
|
408
417
|
g.branch('existing_branch').checkout
|
409
|
-
g.branch('
|
418
|
+
g.branch('main').contains?('existing_branch')
|
410
419
|
|
411
420
|
# delete remote branch
|
412
421
|
g.push('origin', 'remote_branch_name', force: true, delete: true)
|
413
422
|
|
414
423
|
g.checkout('new_branch')
|
415
|
-
g.checkout('new_branch', new_branch: true, start_point: '
|
424
|
+
g.checkout('new_branch', new_branch: true, start_point: 'main')
|
416
425
|
g.checkout(g.branch('new_branch'))
|
417
426
|
|
418
427
|
g.branch(name).merge(branch2)
|
@@ -422,7 +431,7 @@ g.branch(name).in_branch(message) { # add files } # auto-commits
|
|
422
431
|
g.merge('new_branch')
|
423
432
|
g.merge('new_branch', 'merge commit message', no_ff: true)
|
424
433
|
g.merge('origin/remote_branch')
|
425
|
-
g.merge(g.branch('
|
434
|
+
g.merge(g.branch('main'))
|
426
435
|
g.merge([branch1, branch2])
|
427
436
|
|
428
437
|
g.merge_base('branch1', 'branch2')
|
data/lib/git/lib.rb
CHANGED
@@ -126,7 +126,7 @@ module Git
|
|
126
126
|
arr_opts = []
|
127
127
|
arr_opts << '--bare' if opts[:bare]
|
128
128
|
arr_opts << '--branch' << opts[:branch] if opts[:branch]
|
129
|
-
arr_opts << '--depth' << opts[:depth].to_i if opts[:depth]
|
129
|
+
arr_opts << '--depth' << opts[:depth].to_i if opts[:depth]
|
130
130
|
arr_opts << '--filter' << opts[:filter] if opts[:filter]
|
131
131
|
Array(opts[:config]).each { |c| arr_opts << '--config' << c }
|
132
132
|
arr_opts << '--origin' << opts[:remote] || opts[:origin] if opts[:remote] || opts[:origin]
|
data/lib/git/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: git
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Scott Chacon and others
|
@@ -248,8 +248,8 @@ licenses:
|
|
248
248
|
metadata:
|
249
249
|
homepage_uri: http://github.com/ruby-git/ruby-git
|
250
250
|
source_code_uri: http://github.com/ruby-git/ruby-git
|
251
|
-
changelog_uri: https://rubydoc.info/gems/git/3.1.
|
252
|
-
documentation_uri: https://rubydoc.info/gems/git/3.1.
|
251
|
+
changelog_uri: https://rubydoc.info/gems/git/3.1.1/file/CHANGELOG.md
|
252
|
+
documentation_uri: https://rubydoc.info/gems/git/3.1.1
|
253
253
|
rdoc_options: []
|
254
254
|
require_paths:
|
255
255
|
- lib
|