-
Notifications
You must be signed in to change notification settings - Fork 1k
Change replace_in_file to return True on success #17531
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
memsharded
merged 1 commit into
conan-io:develop2
from
mrbean-bremen:replace-returns-true
Dec 27, 2024
Merged
Change replace_in_file to return True on success #17531
memsharded
merged 1 commit into
conan-io:develop2
from
mrbean-bremen:replace-returns-true
Dec 27, 2024
+14
−3
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- was inconsistent before: returned False if the pattern was not found (with strict off), otherwise None
franramirez688
approved these changes
Dec 27, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank @mrbean-bremen for this contribution!
LGTM! 😁
AbrilRBS
approved these changes
Dec 27, 2024
memsharded
approved these changes
Dec 27, 2024
memsharded
pushed a commit
to memsharded/conan
that referenced
this pull request
Jan 15, 2025
- was inconsistent before: returned False if the pattern was not found (with strict off), otherwise None
memsharded
added a commit
that referenced
this pull request
Jan 21, 2025
* extra patches path * Update conan/tools/files/patches.py Co-authored-by: Andrey Filipenkov <kambaladecapitator@gmail.com> * fix docstring of Environment.vars() (#17521) fix docstring of vars() * GnuToolchain's make_args handle empty values correctly (#17532) test * Change replace_in_file to return True on success (#17531) - was inconsistent before: returned False if the pattern was not found (with strict off), otherwise None * upgrade bottle version (#17534) * better traces and msgs (#17517) * better traces and msgs * fix tests * Feature/workspace api (#17501) * working in workspace_api * fixed loader + run() error * update webtest testing version (#17537) * proposing new --format=<format> --out-file=<file.ext> feature (#17507) * proposing new --format=file.ext feature * change approach and some simplifications * remove unused * minor changes * minor changes * simplify a bit * fix format * minor changes * fix * move colorama deinit/reinit * add out-file only if formatters * revert * wip * do not deinit/reinit if not tty * clean import * minor changes --------- Co-authored-by: czoido <mrgalleta@gmail.com> * Test/remote login (#17552) * new test for remote_login * unittest->pytest * Keep sessions around between each ConanRequester (#17455) * Keep sessions around between each ConanRequester Avoid creating a new session for each ConanRequester instance, this helps a lot with performance, as it avoids the overhead duplicate handshakes * Patch new cached value on ConanRequester tests * Modify adapter as needed * Fix tests * Name * Update conans/client/rest/conan_requester.py * Refactor requester tests * Reinit is not part of this PR * Refactor request usage out of app * Make max_retries a local variable * Add rest of posible `ConanBasicApp` usages (#17555) Add rest of posible ConanBasicApp usages * Improve typing information in remove sub API (#17564) As the API actually accepts the remote to be `None`, this should also be reflected in the type information in order to support users. * small refactor to PkgConfigDeps (#17568) * Updated to use maxsplit=1 (#17571) * Updated to use maxsplit=1 * Add tests, unquote paths with spaces --------- Co-authored-by: Abril Rincón Blanco <git@rinconblanco.es> * refactor moving model conans->conan (#17572) * refactor moving model conans->conan * fix tests * allow non trim_conandata * removed print --------- Co-authored-by: Andrey Filipenkov <kambaladecapitator@gmail.com> Co-authored-by: Andrey Filipenkov <decapitator@ukr.net> Co-authored-by: Ernesto de Gracia Herranz <ernestodgh@jfrog.com> Co-authored-by: mrbean-bremen <mrbean-bremen@users.noreply.github.com> Co-authored-by: czoido <mrgalleta@gmail.com> Co-authored-by: Abril Rincón Blanco <rubenrb@jfrog.com> Co-authored-by: Martin Lambertsen <github@lambertsen.one> Co-authored-by: maitrey <maitreymishra23@gmail.com> Co-authored-by: Abril Rincón Blanco <git@rinconblanco.es>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
False
if the pattern was not found (with strict off), otherwiseNone
Changelog: Fix: Fix inconsistency in
replace_in_file
, that returnedFalse
if the pattern was not found (with strict off), otherwiseNone
.Docs: Omit
develop
branch, documenting this one.