Commit graph

14659 commits

Author SHA1 Message Date
tomoya ishida
ba01d15cf5 [ruby/reline] Reline::ANSI is general io. Reline::GeneralIO is not.
(https://github.com/ruby/reline/pull/659)

Reline::ANSI has a partial non-tty supporting code. It should be a general io.
Reline::Dumb should be only used in testing.

2d6828473d
2024-06-03 14:28:33 +00:00
Hiroaki Osawa
5d33ff36dc [ruby/reline] In ed_search_[prev|next]_history, make the cursor come
to the end of the line when there is no search substr
(https://github.com/ruby/reline/pull/714)

* In ed_search_prev_history, make the cursor come to the end of the line when there is no search substr

* In ed_search_next_history, make the cursor come to the end of the line when there is no search substr

* Implemented ActionState to search with empty substr if the previous operation was search with empty string.

* Use a simple 2-element array to represent action_state

95ee80bd70
2024-06-03 14:05:51 +00:00
tomoya ishida
91d4a7ae0c [ruby/reline] Improve key binding match/matching check
(https://github.com/ruby/reline/pull/709)

* Improve key binding match/matching check

* Rename key_actors to default_key_bindings

* Make key_stroke.expand always return a value

* Update add_default_key_binding to use a add_default_key_binding_by_keymap internally

Co-authored-by: Stan Lo <stan001212@gmail.com>

---------

353ec236e2

Co-authored-by: Stan Lo <stan001212@gmail.com>
2024-06-03 13:15:05 +00:00
Tanaka Akira
fc495951b1 Tempfile document updated. 2024-06-02 01:12:26 +09:00
Stan Lo
cda69b5910 [ruby/reline] Overhaul io gate structure
(https://github.com/ruby/reline/pull/666)

* Overhaul IO gate structure

1. Move IO related classes to `lib/reline/io/` directory.
2. Rename `GeneralIO` to `Dumb`.
3. Use IO classes as instances instead of classes.

* Update lib/reline/io/ansi.rb

Co-authored-by: tomoya ishida <tomoyapenguin@gmail.com>

---------

dc1518e1ac

Co-authored-by: tomoya ishida <tomoyapenguin@gmail.com>
2024-06-01 10:28:08 +00:00
akr
3ee83c73c3
Tempfile.create(anonymous: true) implemented. (#10803)
The keyword argument `anonymous` is implemented for `Tempfile.create`

The default is `anonymous: false`.
The behavior is not changed as before.

The created temporary file is immediately removed if `anonymous: true` is specified.
So applications don't need to remove the file.
The actual storage of the file is reclaimed by the OS when the file is closed.

It uses `O_TMPFILE` for Linux 3.11 or later.
It creates an anonymous file from the beginning.

It uses FILE_SHARE_DELETE for Windows.
It makes it possible to remove the opened file.

[Feature #20497]
2024-06-01 15:11:19 +09:00
Martin Emde
bc40d06091 [rubygems/rubygems] String search based parsing of compact index versions
This significantly reduces memory usage.

8a76506c90
2024-05-31 20:20:03 +00:00
Kevin Newton
b5c8fb9a3f [ruby/prism] Fix up heredoc location translation for parser
a4e164e22b
2024-05-31 19:31:53 +00:00
Kevin Newton
63ea77916a [ruby/prism] Match % strings in parser
840185110f
2024-05-31 19:31:53 +00:00
Kevin Newton
1b392ba7c6 [ruby/prism] Use correct opening and closing parenthesis for array pattern in parser
beed43922c
2024-05-31 19:31:53 +00:00
Kevin Newton
47f05dffa1 [ruby/prism] Match match_hash_var when quotes are used
f2a327449a
2024-05-31 19:31:52 +00:00
Kevin Newton
02b27aca50 [ruby/prism] Match parser for match_rest in pattern
785de2c39d
2024-05-31 19:31:52 +00:00
Martin Emde
78860b8e52 [rubygems/rubygems] Move compact index concurrency to fetcher
ffd3711d00
2024-05-31 16:41:25 +00:00
David Rodríguez
10c256f98f Sychronize with rubygems/rubygems repo 2024-06-01 01:13:55 +09:00
David Rodriguez
8e2a6435e4 [rubygems/rubygems] Fix gem uninstall warning when two versions of psych installed
1b5644b666
2024-05-31 15:09:37 +00:00
David Rodríguez
f4f56b23c3 [rubygems/rubygems] Make stub sorting stable
6b70e9043d
2024-05-31 11:58:00 +00:00
Kevin Newton
72452f4387 [ruby/prism] Tests overhaul
6f886be0a4
2024-05-30 15:18:20 -04:00
David Rodríguez
4f160ad9cf [rubygems/rubygems] Don't let bundle config report a path without a Gemfile as "local app"
6aa2ac337f
2024-05-30 18:23:36 +00:00
Brandon Weaver
bc6860db23 [ruby/net-http] Update lib/net/http/header.rb
826e008cfe

Co-authored-by: Jean Boussier <jean.boussier@gmail.com>
2024-05-30 09:16:15 +00:00
Brandon Weaver
4839493f3f [ruby/net-http] Replace Regexp in for headers for perf
15f1349e4e
2024-05-30 09:16:15 +00:00
Zopolis4
4d744a7aa7 [ruby/net-http] Add Net::HTTP.put method
6dc01c985b
2024-05-30 09:02:32 +00:00
Hiroshi SHIBATA
f23c96581f
Update generated code from 5c7ea6fa15 2024-05-30 18:00:25 +09:00
Hiroshi SHIBATA
ba8e6e77fd
Revert "[rubygems/rubygems] Fix gem pristine sometimes failing to pristine user installed gems"
This reverts commit a3edc4abc5.

That commit caused test failure with Windows platform.

* 2556187139
* 2556187306
2024-05-30 12:46:19 +09:00
Adam Daniels
01aa77faa2 [ruby/rdoc] Abort with error message if --dump argument invalid
When --dump=FILE is passed a path that does not exist or is not
readable, it silently fails.

0536b83c46
2024-05-30 00:09:22 +00:00
David Rodriguez
a3edc4abc5 [rubygems/rubygems] Fix gem pristine sometimes failing to pristine user installed gems
0eb6ed8f86
2024-05-29 15:35:04 +00:00
Mari Imaizumi
b0e6446b9f [ruby/reline] Bump version to 0.5.8
(https://github.com/ruby/reline/pull/711)

43cd4c5d58
2024-05-29 14:45:39 +00:00
David Rodríguez
939d389c54 [rubygems/rubygems] Improve default gem handling by treating default gems as any other gem
For backwards compatibility, make sure default gems are still used as a
last resort when materializing, in case no remote, cached, or installed
specs are found.

93788f689f
2024-05-29 13:55:25 +00:00
Darren Kavanagh
2c8b2f5b55 [rubygems/rubygems] Clarify BUNDLE_USER_CONFIG is a file
0b284fc88c
2024-05-28 20:15:45 +00:00
David Rodríguez
6b3935250e [rubygems/rubygems] Bump COCs to latest Contributor Covenant version
73794a95b9
2024-05-28 15:10:59 +00:00
verdy89
7c6e4bc7ca [ruby/reline] Implement the redo command
(https://github.com/ruby/reline/pull/707)

* Implement the redo command

* Commented out a test that does not pass

* Changed key assignment for redo from "\C-[" to "\C-g"

* Changed redo key assignment from `\C-g` to `\M-\C-_`

* Revert the first implemantation

* Implemented redo by sharing `@past_lines` between undo and redo

* Fixed the index of past_lines that is updated when the cursor is moved

* Fixed deletion of the redo history in regular input

* Renamed variables: past_lines -> input_lines

* Rename @position to @input_lines_position

* Deleted unused variables: `@old_byte_pointer` and `@old_line_index`

0b2d9fab5f
2024-05-27 16:38:22 +00:00
License Update
5853a38043 [rubygems/rubygems] Update SPDX license list as of 2024-05-22
f91ac04397
2024-05-27 01:45:38 +00:00
Marcus Stollsteimer
4949f0a928 [rubygems/rubygems] Fix typo in description of build:checksum task
351ff2512f
2024-05-26 21:42:45 +00:00
Go
508f331048 [ruby/reline] allow space in config value
(https://github.com/ruby/reline/pull/705)

* allow space in config value

fix https://github.com/ruby/reline/pull/657

* remove inline comments

* Revert "remove inline comments"

This reverts commit 2438347c1a.

* refactoring

* remove unnecessary comment handling

d60f1e1e39
2024-05-26 08:28:25 +00:00
Martin Emde
6b0afbb111 [rubygems/rubygems] Reorganize and refactor CompactIndexClient
71bcf354f5
2024-05-25 17:47:07 +00:00
Jacklyn Ma
4d0c5486a2 [rubygems/rubygems] update cache checksums to decrease string allocations
85371a961a
2024-05-24 21:04:21 +00:00
Kevin Newton
c7281e2d67 [ruby/prism] Fix up ruby_parser string concat
4b06eae0df
2024-05-24 19:27:44 +00:00
Kevin Newton
f8b750370e [ruby/prism] Remove Debug module
4d8929ff6a
2024-05-24 17:19:38 +00:00
Kevin Newton
745a948b6d [ruby/prism] Remove dynamic Debug module methods
b850794db9
2024-05-24 17:19:36 +00:00
David Rodríguez
6a7e4c40e1 [rubygems/rubygems] Neither --force flag or inline mode should mandate a remote resolution
50dd93e217
2024-05-24 15:02:31 +00:00
David Rodríguez
eef125fd09 [rubygems/rubygems] Fix error messages to not mention cached gems when they were not used
5ce9a7ff17
2024-05-24 15:02:30 +00:00
David Rodríguez
744dd5a362 [rubygems/rubygems] Fix performance regression on applications with a local cache
Even if all gems are properly installed and no resolve is needed, we
recently started always reading all packages in `vendor/cache` and
extracting specifications from them.

This commit fixes the problem by longer making considering cached specs
the default and only enable them when a resolve is actually needed.

edeb2c42bf
2024-05-24 15:02:30 +00:00
David Rodríguez
c23798c2c4 [rubygems/rubygems] Remove @remote instance variable from Definition
It's a sources specific concern, so keep it there. It allows to simplify
the code quite a lot.

639f0b72f4
2024-05-24 15:02:30 +00:00
David Rodríguez
ea7e3e7b78 [rubygems/rubygems] Give better message when resolving because there's no lockfile
4e048bc255
2024-05-24 15:02:29 +00:00
David Rodríguez
0f9781b5c1 [rubygems/rubygems] Use Definition#no_resolve_needed?
5074c58ffb
2024-05-24 15:02:29 +00:00
David Rodríguez
3832a1bda8 [rubygems/rubygems] Make code more symmetric
dc7c9f029a
2024-05-24 15:02:28 +00:00
Martin Emde
acdd19facc [rubygems/rubygems] Fiks speeling cott bye codespell
508ed917a5
2024-05-24 01:53:35 +00:00
Martin Emde
76e31d9aa9 [rubygems/rubygems] Remove MD5 ETag generation from compact index
This was an offramp for generated etags to allow existing caches
to be served until people could upgrade. It has been about 6 months
since the transitional version was released, so we can remove this
transitional code now.

4ec8cfe611
2024-05-23 22:57:26 +00:00
Hiroshi SHIBATA
2cc047df9a [ruby/rdoc] Bump up 6.7.0
a667e616e1
2024-05-23 01:17:32 +00:00
Kevin Newton
e575954887 [ruby/prism] Fix support for 'it' implicit local variable
53bbcfe513
2024-05-22 16:34:04 -04:00
Ellen Keal
5b9b6b4d2b [rubygems/rubygems] move git clone depth error handling to else branch
022eb473f8
2024-05-22 06:01:51 +00:00